Browse Source

Tests: PityTest - transport var rename

LIB-11
heck 4 years ago
parent
commit
4e571998cc
  1. 8
      test/pitytest11/src/PityTransport.cc
  2. 2
      test/pitytest11/src/PityTransport.hh

8
test/pitytest11/src/PityTransport.cc

@ -74,7 +74,9 @@ namespace pEp {
return ret;
}
std::string PityTransport::receiveMsg(int timeout_msec) const
// Blocking
// Returns when a msg has been received
std::string PityTransport::receiveMsg(int poll_interval) const
{
pEpLogClass("called");
std::string ret;
@ -84,8 +86,8 @@ namespace pEp {
ret = pollMsg();
retry = false;
} catch (const std::underflow_error&) {
pEpLogClass("polling again in [ms]: " + std::to_string(timeout_msec) + "...");
Utils::sleep_millis(timeout_msec);
pEpLogClass("polling again in [ms]: " + std::to_string(poll_interval) + "...");
Utils::sleep_millis(poll_interval);
retry = true;
}
} while (retry);

2
test/pitytest11/src/PityTransport.hh

@ -25,7 +25,7 @@ namespace pEp {
bool hasMsg() const;
void sendMsg(const std::string nodename, const std::string& msg) const;
std::string pollMsg() const;
std::string receiveMsg(int timeout_msec = 100) const;
std::string receiveMsg(int poll_interval = 100) const;
//internal logging
static bool debug_log_enabled;

Loading…
Cancel
Save