Page MenuHomePhabricator

Establish base unit test coverage of MW-Vagrant plugin classes/modules
Closed, ResolvedPublic


As part of an effort to improve the overall stability of MW-Vagrant, we should establish decent unit-test coverage for the plugin classes/modules using rspec and possibly vagrant-spec. Good baseline coverage (and continuing coverage) will protect against regression during development of new features, fixes, and refactoring.

The test suite should be easily runnable by developers before pushing commits and runnable by CI before merges using bundle exec rspec. It may make sense to keep unit tests separate from any functional/acceptance tests we might develop, so as not to muddle the utility of each.

It might also be a good idea to include measurement of coverage with something like simplecov, not so much to measure the absolute health of the project but to measure changes over time—awareness of an incline/decline in coverage will help promote TDD.

Event Timeline

dduvall claimed this task.
dduvall raised the priority of this task from to Needs Triage.
dduvall updated the task description. (Show Details)
dduvall added a project: MediaWiki-Vagrant.
dduvall changed Security from none to None.
dduvall added subscribers: ori, bd808, hashar.
bd808 triaged this task as Medium priority.Dec 30 2014, 1:51 AM
gerritbot added a subscriber: gerritbot.

Change 185350 had a related patch set uploaded (by Dduvall):
WIP Unit tests for Environment class


Change 185399 had a related patch set uploaded (by Hashar):
Experimental mediawiki-vagrant-bundle-rspec job


Change 185399 merged by jenkins-bot:
Experimental mediawiki-vagrant rspec and rubocop jobs

I have added Jenkins jobs for rspec and rubocop in the experimental pipeline. Can be triggered by commenting in Gerrit 'check experimental'.

Once the patch is ready/merged, we can move the rspec job to the test/gate-and-submit pipeline.

Change 185350 merged by Dduvall:
Unit tests for Environment class

Change 189098 had a related patch set uploaded (by Dduvall):
Unit tests for settings classes


Change 189098 merged by jenkins-bot:
Unit tests for settings classes

dduvall reopened this task as Open.

Gah. Sorry, this shouldn't be resolved until the rspec job is fixed and voting.

Change 192857 had a related patch set uploaded (by Dduvall):
Make mediawiki-vagrant rspec job voting

Change 192857 merged by jenkins-bot:
Make mediawiki-vagrant rspec job voting