• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Python test.run函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Python中setuptools.command.test.test.run函数的典型用法代码示例。如果您正苦于以下问题:Python run函数的具体用法?Python run怎么用?Python run使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了run函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Python代码示例。

示例1: run

 def run(self):
     # Evita que as dependências sejam instaladas em um diretório ".egg/"
     # durante os testes, o que é útil se você estiver depurando usando
     # virtualenv e quer que sejam utilizadas as dependências já disponíveis
     # no ambiente virtual.
     self.distribution.install_requires = []
     TestCommand.run(self)
开发者ID:base4sistemas,项目名称:satextrato,代码行数:7,代码来源:setup.py


示例2: run

    def run(self):
        entry_points = os.path.join('distribute.egg-info', 'entry_points.txt')

        if not os.path.exists(entry_points):
            try:
                _test.run(self)
            finally:
                return

        f = open(entry_points)

        # running the test
        try:
            ep_content = f.read()
        finally:
            f.close()

        try:
            _test.run(self)
        finally:
            # restoring the file
            f = open(entry_points, 'w')
            try:
                f.write(ep_content)
            finally:
                f.close()
开发者ID:btubbs,项目名称:heroku-buildpack-python,代码行数:26,代码来源:setup.py


示例3: run

    def run(self):
        test.run(self)

        import nose
        import logging
        logging.disable(logging.CRITICAL)
        nose.main(argv=['tests', '-v'])
开发者ID:damirazo,项目名称:frontik,代码行数:7,代码来源:setup.py


示例4: run

 def run(self):
   test.run(self)
   import pytest
   cov = ''
   if self.pytest_cov is not None:
     outputs = ' '.join('--cov-report %s' % output
                        for output in self.pytest_cov.split(','))
     cov = ' --cov openhtf ' + outputs
   sys.exit(pytest.main(self.pytest_args + cov))
开发者ID:pombredanne,项目名称:openhtf,代码行数:9,代码来源:setup.py


示例5: run

    def run(self):
        # Call this to do complicated distribute stuff.
        original_test.run(self)

        for cmd in ['nosetests']:
            try:
                self.run_command(cmd)
            except SystemExit, e:
                if e.code:
                    raise
开发者ID:mforbes,项目名称:nbdiff,代码行数:10,代码来源:setup.py


示例6: run

	def run(self):
		if options.cpptests:
			optimize = "Dbg"
			comp_cmd = ["scons", "--optimize={0}".format(optimize), "--target=Tests", "-j{0}".format(jobs)]
			print("initializing NetworKit compilation with: {0}".format(" ".join(comp_cmd)))
			if not subprocess.call(comp_cmd) == 0:
				print("scons returned an error, exiting setup.py")
				exit(1)
			run_cpp_cmd = ["./NetworKit-Tests-{0}".format(optimize),"-t"]
			if subprocess.call(run_cpp_cmd) == 0:
				print("C++ unit tests didn't report any errors")
			else:
				print("some C++ unit tests failed, see above")
		TestCommand.run(self)
开发者ID:maxvogel,项目名称:NetworKit-mirror2,代码行数:14,代码来源:setup.py


示例7: run

 def run(self):
     if self.verbosity > 0:
         # ensure that deprecation warnings are displayed during testing
         # the following state is assumed:
         # logging.capturewarnings is true
         # a "default" level warnings filter has been added for
         # DeprecationWarning. See django.conf.LazySettings._configure_logging
         logger = logging.getLogger('py.warnings')
         handler = logging.StreamHandler()
         logger.addHandler(handler)
     TestCommand.run(self)
     if self.verbosity > 0:
         # remove the testing-specific handler
         logger.removeHandler(handler)
开发者ID:georgemarshall,项目名称:django-cryptography,代码行数:14,代码来源:setup.py


示例8: run

 def run(self):
     if sys.platform == 'darwin':
         # Docker for Mac exports certain paths into the virtual machine
         # actually running Docker. The default tempdir isn't one of them,
         # but /tmp is.
         os.environ['TMPDIR'] = '/tmp'
     return TestCommand.run(self)
开发者ID:geerlingguy,项目名称:ansible-container,代码行数:7,代码来源:setup.py


示例9: run

    def run(self):
        entry_points = os.path.join('setuptools.egg-info', 'entry_points.txt')

        if not os.path.exists(entry_points):
            _test.run(self)
            return # even though _test.run will raise SystemExit

        # save the content
        with open(entry_points) as f:
            ep_content = f.read()

        # run the test
        try:
            _test.run(self)
        finally:
            # restore the file
            with open(entry_points, 'w') as f:
                f.write(ep_content)
开发者ID:youniforever,项目名称:rasp-bak,代码行数:18,代码来源:setup.py


示例10: run

    def run(self):
        # Install dependencies
        if self.distribution.install_requires:
            self.distribution.fetch_build_eggs(
                self.distribution.install_requires)
        if self.distribution.tests_require:
            self.distribution.fetch_build_eggs(self.distribution.tests_require)

        # Use the flake8 setup.py command (declared via entry_points in flake8's setup.py)
        self.run_command("flake8")

        # Run the unittests as normal
        return test_cmd.run(self)  # Can't use super() since test_cmd is an old-style class...
开发者ID:dhui,项目名称:awaredatetime,代码行数:13,代码来源:setup.py


示例11: run

    def run(self):
        # Make sure all modules are ready
        build_cmd = self.get_finalized_command("build_py")
        build_cmd.run()
        # And make sure our scripts are ready
        build_scripts_cmd = self.get_finalized_command("build_scripts")
        build_scripts_cmd.run()

        # make symlinks for test data
        if build_cmd.build_lib != top_dir:
            for path in ['testfiles.tar.gz', 'gnupg']:
                src = os.path.join(top_dir, 'testing', path)
                target = os.path.join(build_cmd.build_lib, 'testing', path)
                try:
                    os.symlink(src, target)
                except Exception:
                    pass

        os.environ['PATH'] = "%s:%s" % (
            os.path.abspath(build_scripts_cmd.build_dir),
            os.environ.get('PATH'))

        test.run(self)
开发者ID:henrysher,项目名称:duplicity,代码行数:23,代码来源:setup.py


示例12: run

    def run(self):
        entry_points = os.path.join('setuptools.egg-info', 'entry_points.txt')

        if not os.path.exists(entry_points):
            _test.run(self)
            return # even though _test.run will raise SystemExit

        f = open(entry_points)

        # running the test
        try:
            ep_content = f.read()
        finally:
            f.close()

        try:
            _test.run(self)
        finally:
            # restoring the file
            f = open(entry_points, 'w')
            try:
                f.write(ep_content)
            finally:
                f.close()
开发者ID:geekman7473,项目名称:TwitterBotTest,代码行数:24,代码来源:setup.py


示例13: run

 def run(self, *args, **kwargs):
     for env_name, env_value in self.extra_env.items():
         os.environ[env_name] = str(env_value)
     TestCommand.run(self, *args, **kwargs)
开发者ID:molotov,项目名称:celery,代码行数:4,代码来源:setup.py


示例14: run

 def run(self):
     test.run(self)
     self.with_project_on_sys_path(self.run_benchmark)
开发者ID:mcdonc,项目名称:chameleon,代码行数:3,代码来源:setup.py


示例15: run

 def run(self):
     self.pep8_report()
     TestCommand.run(self)
开发者ID:randomknowledge,项目名称:django-push-notifications,代码行数:3,代码来源:setup.py


示例16: run

 def run(self):
     self.run_command("build_py")
     _test.run(self)
开发者ID:pombredanne,项目名称:py-dom-xpath,代码行数:3,代码来源:setup.py


示例17: run

 def run(self):
     import csslex, cssyacc
     csslex._build()
     cssyacc._build()
     test.run(self)
开发者ID:matematik7,项目名称:CSSQC,代码行数:5,代码来源:setup.py


示例18: run

 def run(self, *args, **kwargs):
     Upgrade().run(dist=True)
     test.run(self, *args, **kwargs)
开发者ID:LucianU,项目名称:kuma-lib,代码行数:3,代码来源:setup.py


示例19: run

 def run(self):
     delete_base_file()
     management.call_command('syncdb', interactive=False)
     #management.call_command('loaddata', 'fixtures.json', interactive=False)
     test.run(self)
开发者ID:rydztom,项目名称:questions2,代码行数:5,代码来源:setup.py


示例20: run

 def run(self):
     with self._save_entry_points():
         _test.run(self)
开发者ID:ptthiem,项目名称:st-testing,代码行数:3,代码来源:setup.py



注:本文中的setuptools.command.test.test.run函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Python compat.unquote函数代码示例发布时间:2022-05-27
下一篇:
Python test.initialize_options函数代码示例发布时间:2022-05-27
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap