File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ import time
2+
13import allure
24import pytest
35
46
57def test_passed ():
8+ time .sleep (1 )
69 assert True
710
811
912@pytest .mark .skip (reason = "This test is skipped" )
1013def test_skipped ():
14+ time .sleep (2 )
1115 assert True
1216
1317
1418def test_broken ():
19+ time .sleep (3 )
1520 raise Exception ("This test is broken" )
1621
1722
1823@allure .title ("This is a step failed_fixture" )
1924@pytest .fixture (scope = "function" )
2025def setup_failed_fixture ():
26+ time .sleep (4 )
2127 raise Exception ("This fixture is broken" )
2228
2329
2430@allure .title ("This test fixture setup is broken" )
2531def test_failed_fixture_setup (failed_fixture ):
2632 with allure .step ("This is a step" ):
27- assert True
33+ time .sleep (5 )
34+ assert failed_fixture
2835
2936
3037@allure .title ("This is a step teardown_fixture" )
3138@pytest .fixture (scope = "function" )
3239def teardown_fixture ():
40+ time .sleep (6 )
3341 yield True
3442 raise Exception ("This fixture is broken" )
3543
3644
3745@allure .title ("This test fixture teardown is broken" )
3846def test_failed_fixture_teardown (teardown_fixture ):
39- with allure .step ("This is a step" ):
47+ with allure .step ("This is a step1" ):
48+ time .sleep (7 )
4049 assert True
41- with allure .step ("This is a step" ):
42- with allure .step ("This is a step" ):
50+ with allure .step ("This is a step2" ):
51+ with allure .step ("This is a step3" ):
52+ time .sleep (8 )
4353 assert True
44- with allure .step ("This is a step" ):
54+ with allure .step ("This is a step4" ):
55+ time .sleep (9 )
4556 assert teardown_fixture
You can’t perform that action at this time.
0 commit comments