bringyourownideas / silverstripe-composer-security-checker

Provides information if your SilverStripe application uses dependencies with known vulnerabilities.
https://bringyourownideas.com
BSD 3-Clause "New" or "Revised" License
9 stars 6 forks source link

Write tests for the DataExtensions #35

Closed NightJar closed 6 years ago

NightJar commented 6 years ago

Integration tests more than unit, however the module currently has support for the silverstripe-maintenance module iff it is installed, but does not test this.

Usage of setUpOnce/setUp to test if the bringyourownideas/silverstripe-maintenance module exists, and using $this->markTestSkipped('Maintenance module not present') would see us able to use some fixtures and test various points of the extensions, such as whether or not the appropriate asset files are included (css,js), outputs are modified, etc.

robbieaverill commented 6 years ago

There's a bunch of situations where we've got extra modules installed in some CI build situations (like adding in subsites or queuedjobs) - would be good to add it for some but not all matrix entries, and ensure that if you're skipping tests that don't have a module present that you'd run code coverage on the run that has the least number of tests skipped =)