wsd: test: give up attempting to connect if the test finished
Some tests are designed to exercise the reconnection logic. Once the test validates that the correct reconnection logic is used, the test is considered finished. In those cases, we need to break the test framework's retry logic. Change-Id: Ie0bb5dcc430a954910c2af4817a500f5b576bd4c Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>pull/8916/head
parent
b38e1f41ea
commit
7268248481
|
@ -11,6 +11,7 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include "Unit.hpp"
|
||||
#include <test/lokassert.hpp>
|
||||
#include <test/testlog.hpp>
|
||||
|
||||
|
@ -572,6 +573,12 @@ connectLOKit(const std::shared_ptr<SocketPoll>& socketPoll, const Poco::URI& uri
|
|||
break;
|
||||
}
|
||||
|
||||
if (UnitBase::get().isFinished())
|
||||
{
|
||||
TST_LOG("The test has finished, giving up connectLOKit");
|
||||
break;
|
||||
}
|
||||
|
||||
TST_LOG("ERROR: Reconnecting (retry #" << (max_retries - retries) << ") to "
|
||||
<< uri.toString());
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue