Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #32967 > unrolled thread
| Started by | Cecil Westerhof <Cecil@decebal.nl> |
|---|---|
| First post | 2015-11-02 11:15 +0100 |
| Last post | 2015-11-03 19:32 +0100 |
| Articles | 3 — 2 participants |
Back to article view | Back to comp.lang.java.programmer
Mockito test are unstable Cecil Westerhof <Cecil@decebal.nl> - 2015-11-02 11:15 +0100
Re: Mockito test are unstable Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2015-11-03 10:11 +0000
Re: Mockito test are unstable Cecil Westerhof <Cecil@decebal.nl> - 2015-11-03 19:32 +0100
| From | Cecil Westerhof <Cecil@decebal.nl> |
|---|---|
| Date | 2015-11-02 11:15 +0100 |
| Subject | Mockito test are unstable |
| Message-ID | <87h9l4k8re.fsf@Equus.decebal.nl> |
I am working on an old project where they are using Mockito for unit testing. The strange problem we have is that when mvn is run several times every time different tests are failing. And sometime no tests are failing. Anyone an idea what could be the problem? -- Cecil Westerhof Senior Software Engineer LinkedIn: http://www.linkedin.com/in/cecilwesterhof
[toc] | [next] | [standalone]
| From | Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> |
|---|---|
| Date | 2015-11-03 10:11 +0000 |
| Message-ID | <slrnn3h26q.jg7.avl@login.logic.tuwien.ac.at> |
| In reply to | #32967 |
Cecil Westerhof <Cecil@decebal.nl> wrote: > I am working on an old project where they are using Mockito for unit > testing. The strange problem we have is that when mvn is run several > times every time different tests are failing. And sometime no tests > are failing. Anyone an idea what could be the problem? I don't know Mockito, but when tests are flaky then probably the tests themselves have Heisenbugs? E.g.: maybe the tests each depend on & modify static data and thus randomly fail when tests are being run concurrently...
[toc] | [prev] | [next] | [standalone]
| From | Cecil Westerhof <Cecil@decebal.nl> |
|---|---|
| Date | 2015-11-03 19:32 +0100 |
| Message-ID | <87r3k7hr20.fsf@Equus.decebal.nl> |
| In reply to | #32981 |
On Tuesday 3 Nov 2015 11:11 CET, Andreas Leitgeb wrote: > Cecil Westerhof <Cecil@decebal.nl> wrote: >> I am working on an old project where they are using Mockito for >> unit testing. The strange problem we have is that when mvn is run >> several times every time different tests are failing. And sometime >> no tests are failing. Anyone an idea what could be the problem? > > I don't know Mockito, but when tests are flaky then probably the > tests themselves have Heisenbugs? > > E.g.: maybe the tests each depend on & modify static data and thus > randomly fail when tests are being run concurrently... I was already for some time telling them that the tests should be independent of each-other. They where adamant that they where, but at last they found they where not. At the moment they included an @After besides the @Before that was already in place to clean things up and until now the problem has not reappeared. So hopefully problem solved. -- Cecil Westerhof Senior Software Engineer LinkedIn: http://www.linkedin.com/in/cecilwesterhof
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.java.programmer
csiph-web