def test_collected_results_serialized_to_settings_based_filename(
settings, tmpfilepath):
class SomeTestCase(unittest.TestCase):
def test_foo(self):
assert 'test name' in ctx.data, ctx.data.keys()
tests = ctx.data['test name']
assert len(tests) == 1
assert [str(self)] == tests
settings.DJPT_DATAFILE_PATH = tmpfilepath
with override_current_context() as ctx:
run_testcases_with_django_runner(SomeTestCase, nr_of_tests=1)
reader = Reader(settings.DJPT_DATAFILE_PATH)
assert [] != reader.read_all()
test_integrates_with_django_testrunner.py 文件源码
python
阅读 22
收藏 0
点赞 0
评论 0
评论列表
文章目录