softwareconstruction240 / autograder

Autograder for BYU's CS 240 Chess project
https://cs240.click
2 stars 2 forks source link

362 incorrect test location #389

Closed Fiwafoofa closed 3 months ago

Fiwafoofa commented 3 months ago

Added TestLocationVerifier to check for unit test location that also verifies package names and added it to the list of verifiers, a helper method to both PhaseUtils and FileUtils, a placeholder test for TestLocationVerifier.java, and moved verifiers and modifiers to their own subpackages.

Resolves issue https://github.com/softwareconstruction240/autograder/issues/362.

One potential concern is code duplication with ProjectStructureVerifier. Both that class and TestLocationVerifier take in paths and verify that they are valid directories. The only difference is that TestLocationVerifier checks for package statements ( package dataaccess) and if it finds a missing package like test/java/service, then it scans the directory for any misnamed or unrecognized packages. As a result, both verifiers have similar warnings.