| 90 | */ |
| 91 | |
| 92 | bool testTryPopWhenNotEmpty(const QueueWrapper& queueWrapper) |
| 93 | { |
| 94 | OperationCountingType::resetCounters(); |
| 95 | waitForNextTick(); |
| 96 | const auto start = TickClock::now(); |
| 97 | uint8_t priority {}; |
| 98 | OperationCountingType testValue {}; // 1 construction |
| 99 | const auto ret = queueWrapper.tryPop(priority, testValue); // 1 swap, 1 destruction |
| 100 | return ret == 0 && start == TickClock::now() && queueWrapper.checkCounters(1, 0, 0, 1, 0, 0, 1) == true; |
| 101 | } |
| 102 | |
| 103 | /** |
| 104 | * \brief Tests QueueWrapper::tryPush(..., const T&) when queue is full - it must fail immediately and return EAGAIN |
no test coverage detected