ebb0f11c

By: Tom Sydney Kerckhove <syd@cs-syd.eu>

Let the resources drive the tests, with scenarioDir

Two places were the same test written out once per file.

A rule's resources are now enumerated rather than named: scenarioDir runs one
test per file in test_resources/Rule/<RuleId>, and whether the file is a case
the rule must stay quiet about or one it must report on comes from its name.
Adding a case is adding a file. The project-level rules get the same treatment
one level up, over directories, since scenarioDir enumerates files.

Each rule directory also gets one assertion over its whole listing, which says
three things at once: there is a clean case, there is a dirty one, and there is
nothing else. A rule with only clean resources would otherwise pass while never
firing, and a file named for neither would sit there unread.

CommentBareTodo gains the case that generality is for: a marker in a block
comment rather than a line comment.

annotate's goldens were one per file too. They are a tree now,
Annotation/to-annotate.golden, mirroring the project it is of, driven by
scenarioDirRecur over that project. A module added to the example gets a golden
without anyone adding a test, and the cabal file beside it is asserted to be
the only thing there that is not a module.