Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/350.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
运行所有Python bdd Behave和unittest_Python_Python 3.x_Bdd_Python Unittest_Python Behave - Fatal编程技术网

运行所有Python bdd Behave和unittest

运行所有Python bdd Behave和unittest,python,python-3.x,bdd,python-unittest,python-behave,Python,Python 3.x,Bdd,Python Unittest,Python Behave,我有一个带有大量单元测试的python应用程序,我使用unittest库实现了这些单元测试 我还使用Behave包实现了许多bdd测试 是否有一种方法可以从一个python文件中运行所有单元测试和bdd测试,并在任何测试失败时立即失败 我不确定如何调用单元测试,但可以添加一个behave特性文件,该文件将实现运行单元测试的步骤。这可能只是behave框架中的另一个特性,例如,“所有单元测试都通过”,您可以有如下场景: Scenario: All unit tests pass Given the

我有一个带有大量单元测试的python应用程序,我使用unittest库实现了这些单元测试

我还使用Behave包实现了许多bdd测试


是否有一种方法可以从一个python文件中运行所有单元测试和bdd测试,并在任何测试失败时立即失败

我不确定如何调用单元测试,但可以添加一个behave特性文件,该文件将实现运行单元测试的步骤。这可能只是behave框架中的另一个特性,例如,“所有单元测试都通过”,您可以有如下场景:

Scenario: All unit tests pass
Given the application is ready to test
When I run the unit tests
Then all unit tests have passed

您的单元测试将作为behave调用的一部分执行。

我不确定您如何调用单元测试,但您可以添加一个behave功能文件,该文件将实现运行单元测试的步骤。这可能只是behave框架中的另一个特性,例如,“所有单元测试都通过”,您可以有如下场景:

Scenario: All unit tests pass
Given the application is ready to test
When I run the unit tests
Then all unit tests have passed

您的单元测试将作为behave调用的一部分执行。

一个简单的shell脚本,包含命令和条件退出?任何连续集成系统?在python文件中,请使用一个简单的shell脚本,同时包含命令和条件退出?有连续集成系统吗?请在python文件中