Page MenuHomePhabricator

Add basic unit tests for the Ballot class [M]
Closed, ResolvedPublic

Description

Add BallotTest class, which should extend MediaWikiUnitTestCase.

The source file should be located in SecurePoll/tests/phpunit/unit and namespaced to MediaWiki\Extensions\SecurePoll\Test\Unit.

This will involve some judgement as to what is worth testing, and what can be tested in a unit test.

We should consider whether it would be helpful to make this test extensible, as a base class for tests for the Ballot subclasses. If extra work is required to do this, we can file it as a follow-up.

Event Timeline

ARamirez_WMF renamed this task from Add basic unit tests for the Ballot class to Add basic unit tests for the Ballot class [M].May 5 2021, 4:34 PM

Change 686791 had a related patch set uploaded (by AGueyte; author: AGueyte):

[mediawiki/extensions/SecurePoll@master] WIP Add unit tests for Ballot class

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

Change 686791 merged by jenkins-bot:

[mediawiki/extensions/SecurePoll@master] Add unit tests for Ballot class

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

Niharika reopened this task as Open.
Niharika closed this task as Resolved.