예제 #1
0
파일: test_wrong.py 프로젝트: ldiary/bdd
 def declare_scenario():
     if multiple:
         scenarios(feature)
     else:
         @scenario(feature, scenario_name)
         def test_scenario():
             pass
예제 #2
0
파일: test_wrong.py 프로젝트: ldiary/bdd
def test_multiple_features_single_file():
    """Test validation error when multiple requirements are placed in a single file."""
    with pytest.raises(exceptions.FeatureError) as excinfo:
        scenarios('wrong_multiple_features.feature')
    assert excinfo.value.args[0] == 'Multiple requirements are not allowed in a single feature file'