openelections / openelections-data-wi

Pre-processed election results for Wisconsin elections
9 stars 9 forks source link

Output files without tests #11

Closed nbdavies closed 6 years ago

nbdavies commented 8 years ago

This is something I can probably help with, but just wanted to get it on the list.

nbdavies commented 7 years ago

Added tests back through 2008 so far.

nbdavies commented 7 years ago

We now have at least one test per year that had an election. A representative sampling per election would be a good goal.

davipo commented 7 years ago

I computed a list of output files that don't appear in wi-elections.feature tests:

20021105__wi__general__ward.csv
20051213__wi__special__primary__ward.csv
20060221__wi__primary__ward.csv
20121106__wi__special__primary__ward.csv
20130402__wi__special__general__ward.csv
20150217__wi__special__primary__ward.csv
20150407__wi__special__general__ward.csv
20150721__wi__special__general__ward.csv
nbdavies commented 7 years ago

There are tests for this in a PR submitted to @davipo's fork. To be combined with one more fix that he has, and then submit to core repo.

davipo commented 7 years ago

Thanks for writing up the tests, Nick. We now have at least one test for each results output file. All tests pass, as of commit bbe7ebe.

nbdavies commented 6 years ago

There are various new input files added, so now we need some tests added to get back to "one test minimum per election/output file".

davipo commented 6 years ago

(Actually, the new data is not yet in this repo, but should be when tests pass and merging is done.)

davipo commented 6 years ago

List of 20 untested results files added to davipo/openelections-data-wi on 2018-03-28:

20110215wiprimaryward.csv 20110712wiprimary-recallward.csv 20110712wispecialprimaryward.csv 20110719wigeneral-recallward.csv 20110719wiprimary-recallward.csv 20110809wigeneral-recallward.csv 20110809wispecialgeneralward.csv 20110816wigeneral-recallward.csv 20120221wiprimaryward.csv 20120508wiprimary-recallward.csv 20130219wiprimaryward.csv 20131022wispecialprimaryward.csv 20131119wispecialgeneralward.csv 20140218wiprimaryward.csv 20140401wigeneralward.csv 20150407wigeneralward.csv 20160216wiprimaryward.csv 20171219wispecialprimaryward.csv 20180116wispecialgeneralward.csv 20180220wiprimaryward.csv

nbdavies commented 6 years ago

A couple more:

davipo commented 6 years ago

3 tests added for 20001107wigeneralward.csv (testing single line header parsing). 1 test added for 20160216wiprimaryward.csv (testing comma before "Branch", and extra space removal).

davipo commented 6 years ago

Nick added many tests for mid-2012 and later files. With recent fixes, these now pass (in davipo fork).

Remaining files without tests:

20110215wiprimaryward.csv 20110712wiprimary-recallward.csv 20110712wispecialprimaryward.csv 20110719wigeneral-recallward.csv 20110719wiprimary-recallward.csv 20110809wigeneral-recallward.csv 20110809wispecialgeneralward.csv 20110816wigeneral-recallward.csv 20120221wiprimary__ward.csv

davipo commented 6 years ago

PR #18 has been merged, it tests the remaining untested output files. I think we can close this now.