https://dev.arvados.org/https://dev.arvados.org/favicon.ico?15576888422017-01-13T02:48:57ZArvadosArvados - Bug #10880: [Tests] Fix flaky test test_callback (tests.test_events.PollClientTestCase)https://dev.arvados.org/issues/10880?journal_id=471602017-01-13T02:48:57ZTom Cleggtom@curii.com
<ul><li><strong>Category</strong> set to <i>Tests</i></li><li><strong>Assigned To</strong> set to <i>Tom Clegg</i></li></ul><p>10880-poll-test-races at <a class="changeset" title="10880: Fix races in event-polling tests. The polling tests were broken because the API stub was ..." href="https://dev.arvados.org/projects/arvados/repository/arvados/revisions/b97d14dbd377cc73854eefe77d6450859a41f6b7">b97d14dbd377cc73854eefe77d6450859a41f6b7</a></p>
<p>copied from commit message:</p>
<p>The polling tests were broken because the API stub was returning its<br />fake events during the "find recent log ID" probe, so they were being<br />thrown away by PollClient and never sent to the test case's callback<br />function.</p>
<p>Most of the tests kept passing anyway, though, because subscribe()<br />itself sends a synthetic {'status':200} event, and this was being<br />misconstrued as confirmation that an event had been retrieved from the<br />API stub.</p>
<p>The false positive was not reliable for test_callback(), though,<br />because it cleared callback_called and tested another event without<br />calling subscribe() again. Sometimes, because the first "wait for<br />event" wasn't really waiting, the test would feed the second event to<br />the stub before PollClient had a chance to do its ID probe, so both<br />events would be dropped and the second "wait for event" would fail.</p>
<p>With the "wait for event" code fixed, it is no longer necessary to<br />close the poll client before checking which filters were used to<br />retrieve events.</p> Arvados - Bug #10880: [Tests] Fix flaky test test_callback (tests.test_events.PollClientTestCase)https://dev.arvados.org/issues/10880?journal_id=471612017-01-13T02:49:42ZTom Cleggtom@curii.com
<ul><li><strong>Description</strong> updated (<a title="View differences" href="/journals/47161/diff?detail_id=45418">diff</a>)</li></ul> Arvados - Bug #10880: [Tests] Fix flaky test test_callback (tests.test_events.PollClientTestCase)https://dev.arvados.org/issues/10880?journal_id=471632017-01-13T02:55:06ZTom Cleggtom@curii.com
<ul><li><strong>Status</strong> changed from <i>In Progress</i> to <i>Resolved</i></li><li><strong>% Done</strong> changed from <i>0</i> to <i>100</i></li></ul><p>Applied in changeset arvados|commit:99b571c9050f28525427c100f9072159a3145bc7.</p>