On 2 Dec 2018, at 17:05, Vincent Massol
<vincent(a)massol.net> wrote:
On 2 Dec 2018, at 17:02, Vincent Massol
<vincent(a)massol.net> wrote:
On 27 Nov 2018, at 18:19, Vincent Massol
<vincent(a)massol.net> wrote:
On 26 Nov 2018, at 00:44, Vincent Massol
<vincent(a)massol.net> wrote:
Hi devs,
I wanted to keep up to date on the list of stuff that we still need to do in the domain
of Docker, CI & Clover, specifically on the domains I’ve been working on. All the
items below are items I need to work on (but any help is welcome of course).
1) Clover pipeline job to modify to add docker-based functional tests: right now the
global TPC is going to decrease because of MenuIT and MailIT. This needs to be fixed ASAP
before we convert too many tests.
This should be good now.
One more idea:
1.1) In the XWiki Clover report, compare the failing tests reported by Clover between old
report (reference point) and the new one to gauge if the TPC computed is meaningful or
not.
1.2) In the XWiki clover report, provide a diff list of executed tests to find out
problems with some tests not executed which would lead to TPC being wrong.
I’ve almost finished to implement this but there’s a problem… For some reason I don’t
understand Clover doesn’t report correctly failing tests:
1) A lot of tests are failing in the clover report but not in the build. For example:
In Clover build logs:
"
[INFO] Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 s - in
IdGeneratorTest
[INFO] Running TransformationContextTest
“
In clover.xml report:
https://gist.github.com/vmassol/c8d3103147ddde3610d0c06bf44e37e1
ie 2 tests failing in IdGeneratorTest: testGenerateUniqueIdWhenInvalidEmptyPrefix &
testGenerateUniqueIdWhenInvalidNonAlphaPrefix
2) Several tests failing in the Clover build logs but not in the clover report. For
example:
In Clover build logs:
“
[ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 139.958 s
<<< FAILURE! - in org.xwiki.menu.test.ui.MenuIT
[ERROR] org.xwiki.menu.test.ui.MenuIT Time elapsed: 139.958 s <<< ERROR!
“
In clover.xml report:
https://gist.github.com/vmassol/b5d3ba0120f08fa6e52e09157cad2a45
ie no failure at all…
Thus it’s not possible to trust the clover.xml report… The only solution I can think of
would be to compare either with the local Maven build logs or with the Jenkins test report
logs. But that means we can’t go back in the past since we don’t have those logs for past
clover reports.
The good news is that when Clover says that tests failed, they actually didn't fail
for a lot of them (However we would need to check if the coverage done by those tests is
included but I think they are from what I see: IdGenerator.java has
coveredelements="75” & elements=“84”. That could be from tests other than
IdGeneratorTest though).
hmm found this in some forum:
“
Regarding, your original question regarding failing tests. Yes, if test is failing Clover
won't include its contribution to overall coverage stats. The reasoning behind this
behavior is that since the test fails, its not trustworthy to say it provide test coverage
(confidence) to your code. “