[
https://issues.apache.org/jira/browse/OAK-5600?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Andrei Dulceanu updated OAK-5600:
---------------------------------
Attachment: OAK-5600.patch
Attaching a partial patch for this issue, covering the checking of a valid
repository. I added 5 test cases, covering different combinations of options
and arguments, both valid and invalid. In order to validate the results of the
checking I had to parse log messages logged by {{ConsistencyChecker}}. For this
I added {{InMemoryAppender}} a mock appender which holds all messages in a
{{StringBuilder}}. I am not sure how this could be achieved in a cleaner way,
please chime in with suggestions if you have.
[~frm], [~mduerig] WDYT?
If you are ok with it, I was thinking to commit these tests for the moment, in
order to unblock OAK-5620 and OAK-5556. I will re-visit this issue afterwards,
adding some tests for a repository containing broken revisions. BTW, how does
one get a broken repository in a reproducible way?
> Test coverage for CheckCommand
> ------------------------------
>
> Key: OAK-5600
> URL: https://issues.apache.org/jira/browse/OAK-5600
> Project: Jackrabbit Oak
> Issue Type: Task
> Components: run, segment-tar
> Reporter: Andrei Dulceanu
> Assignee: Andrei Dulceanu
> Priority: Minor
> Labels: tooling
> Fix For: 1.7.0, 1.8
>
> Attachments: OAK-5600.patch
>
>
> We should add tests for {{o.a.j.o.r.CheckCommand}} in order to validate
> recent changes introduced by adding/removing options and their arguments (see
> OAK-5275, OAK-5276, OAK-5277, OAK-5595). There is also a new feature
> introduced by OAK-5556 (filter paths and refactoring proposed) which must be
> thoroughly tested in order to avoid regressions.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)