def test_sets_specified_id(self):
     raw_test = self.ReferenceTest('test_pass')
     raw_id = "testscenarios.tests.test_scenarios.ReferenceTest.test_pass"
     scenario_name = self.scenario_name
     expect_id = "%(raw_id)s(%(scenario_name)s)" % vars()
     modified_test = apply_scenario(self.scenario, raw_test)
     self.assertEqual(expect_id, modified_test.id())
Beispiel #2
0
 def test_sets_specified_id(self):
     raw_test = self.ReferenceTest('test_pass')
     raw_id = "ReferenceTest.test_pass"
     scenario_name = self.scenario_name
     expect_id = "%(raw_id)s(%(scenario_name)s)" % vars()
     modified_test = apply_scenario(self.scenario, raw_test)
     self.expectThat(modified_test.id(), EndsWith(expect_id))
Beispiel #3
0
 def test_sets_specified_id(self):
     raw_test = self.ReferenceTest('test_pass')
     raw_id = "ReferenceTest.test_pass"
     scenario_name = self.scenario_name
     expect_id = "%(raw_id)s(%(scenario_name)s)" % vars()
     modified_test = apply_scenario(self.scenario, raw_test)
     self.expectThat(modified_test.id(), EndsWith(expect_id))
Beispiel #4
0
 def test_sets_specified_id(self):
     raw_test = self.ReferenceTest('test_pass')
     raw_id = "testscenarios.tests.test_scenarios.ReferenceTest.test_pass"
     scenario_name = self.scenario_name
     expect_id = "%(raw_id)s(%(scenario_name)s)" % vars()
     modified_test = apply_scenario(self.scenario, raw_test)
     self.assertEqual(expect_id, modified_test.id())
 def test_appends_scenario_name_to_short_description(self):
     raw_test = self.ReferenceTest('test_pass_with_docstring')
     modified_test = apply_scenario(self.scenario, raw_test)
     raw_doc = self.ReferenceTest.test_pass_with_docstring.__doc__
     raw_desc = raw_doc.split("\n")[0].strip()
     scenario_name = self.scenario_name
     expect_desc = "%(raw_desc)s (%(scenario_name)s)" % vars()
     self.assertEqual(expect_desc, modified_test.shortDescription())
Beispiel #6
0
 def test_appends_scenario_name_to_short_description(self):
     raw_test = self.ReferenceTest('test_pass_with_docstring')
     modified_test = apply_scenario(self.scenario, raw_test)
     raw_doc = self.ReferenceTest.test_pass_with_docstring.__doc__
     raw_desc = raw_doc.split("\n")[0].strip()
     scenario_name = self.scenario_name
     expect_desc = "%(raw_desc)s (%(scenario_name)s)" % vars()
     self.assertEqual(expect_desc, modified_test.shortDescription())
 def test_sets_specified_attributes(self):
     raw_test = self.ReferenceTest('test_pass')
     modified_test = apply_scenario(self.scenario, raw_test)
     self.assertEqual('bar', modified_test.foo)
Beispiel #8
0
 def test_sets_specified_attributes(self):
     raw_test = self.ReferenceTest('test_pass')
     modified_test = apply_scenario(self.scenario, raw_test)
     self.assertEqual('bar', modified_test.foo)