Skip to content

Commit

Permalink
I guess this has to be in on the big test too
Browse files Browse the repository at this point in the history
  • Loading branch information
palewire committed Apr 17, 2018
1 parent cb4b1ed commit d256caa
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 18 deletions.
18 changes: 0 additions & 18 deletions calaccess_processed/tests/test_elections.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,24 +49,6 @@ def test_2010_general_date(self):
)


class CorrectionsTest(TestCase):
"""
Test our corrections.
"""
def test_correction(self):
"""
Test that we can retrieve a correction directly.
"""
from calaccess_processed_elections import corrections
correx = corrections.candidate_party(
"WINSTON, ALMA MARIE",
"2014",
"PRIMARY",
"GOVERNOR"
)
self.assertEqual(correx.name, "REPUBLICAN")


class ScrapedCandidatElectioneNameParsingTest(TestCase):
"""
Test how candidate names are parsed from scraped data.
Expand Down
13 changes: 13 additions & 0 deletions calaccess_processed/tests/test_processing.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,19 @@ def test_scraped_propositions(self):
BallotMeasureContest.objects.count(),
)

def test_correction(self):
"""
Test that we can retrieve a correction directly.
"""
from calaccess_processed_elections import corrections
correx = corrections.candidate_party(
"WINSTON, ALMA MARIE",
"2014",
"PRIMARY",
"GOVERNOR"
)
self.assertEqual(correx.name, "REPUBLICAN")

def test_correction_assignment_by_proxy(self):
"""
Test that a correction is properly being applied when parties are retrieved.
Expand Down

0 comments on commit d256caa

Please sign in to comment.