Skip to content

Commit

Permalink
correct fixture names in test
Browse files Browse the repository at this point in the history
  • Loading branch information
mikealfare committed Sep 29, 2023
1 parent 5c0fff3 commit 6806364
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,10 @@ def test_tests_run_successfully_and_are_persisted_correctly(self, project):
# set up the expected results
TestResult = namedtuple("TestResult", ["name", "status", "type", "row_count"])
expected_results = {
TestResult("pass_with_view_strategy", TestStatus.Pass, "view", 0),
TestResult("fail_with_view_strategy", TestStatus.Fail, "view", 1),
TestResult("pass_with_table_strategy", TestStatus.Pass, "table", 0),
TestResult("fail_with_table_strategy", TestStatus.Fail, "table", 1),
TestResult("pass_as_view", TestStatus.Pass, "view", 0),
TestResult("fail_as_view", TestStatus.Fail, "view", 1),
TestResult("pass_as_table", TestStatus.Pass, "table", 0),
TestResult("fail_as_table", TestStatus.Fail, "table", 1),
}

# run the tests once
Expand All @@ -79,8 +79,8 @@ def test_tests_run_successfully_and_are_persisted_correctly(self, project):
# insert a new record in the model that fails the "pass" tests
# show that the view updates, but not the table
self.insert_record(project, {"name": "dave", "shirt": "grape"})
expected_results.remove(TestResult("pass_with_view_strategy", TestStatus.Pass, "view", 0))
expected_results.add(TestResult("pass_with_view_strategy", TestStatus.Pass, "view", 1))
expected_results.remove(TestResult("pass_as_view", TestStatus.Pass, "view", 0))
expected_results.add(TestResult("pass_as_view", TestStatus.Pass, "view", 1))

# delete the original record from the model that failed the "fail" tests
# show that the view updates, but not the table
Expand Down

0 comments on commit 6806364

Please sign in to comment.