Page MenuHomePhabricator

Add integration tests for the Election class
Closed, ResolvedPublic

Description

This class contains code that determines voter eligibility and some other functions that interact with the database.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

Change #1113237 had a related patch set uploaded (by Amdrel; author: Amdrel):

[mediawiki/extensions/SecurePoll@master] Add voter eligibility tests for the Election class

https://gerrit.wikimedia.org/r/1113237

Change #1113237 merged by jenkins-bot:

[mediawiki/extensions/SecurePoll@master] Add voter eligibility tests for the Election class

https://gerrit.wikimedia.org/r/1113237

Change #1164486 had a related patch set uploaded (by Amdrel; author: Amdrel):

[mediawiki/extensions/SecurePoll@master] Add more tests for a few Election.php methods

https://gerrit.wikimedia.org/r/1164486

Change #1164486 merged by jenkins-bot:

[mediawiki/extensions/SecurePoll@master] Add more tests for a few Election.php methods

https://gerrit.wikimedia.org/r/1164486

Code coverage report for the Election class:

https://doc.wikimedia.org/cover-extensions/SecurePoll/includes/Entities/Election.php.html

Currently at 66% for lines, 46% for functions and methods.

image.png (1×1 px, 185 KB)

Should think about what we want the acceptance criteria to be. Perhaps related to the code coverage report.

I think this should be fine to close if you think there are enough tests for now. Not sure Trust and Safety Product Team would be adding more tests for this in the short term.

I'm going to BOLDly close this as resolved. Tests were added and I don't think more tests are coming soon. If test coverage should improve, I think we would need a new "improve test coverage to X" ticket