diff --git a/.github/workflows/unit-tests.yml b/.github/workflows/unit-tests.yml index 2cd4061..1c492f9 100644 --- a/.github/workflows/unit-tests.yml +++ b/.github/workflows/unit-tests.yml @@ -23,4 +23,5 @@ jobs: build-dir: ${{ runner.workspace }}/build', build-type: ${{ matrix.config }} configure-options: -Wno-dev -DCMAKE_CXX_FLAGS=-std=c++11 - run-test: false \ No newline at end of file + run-test: ${{ matrix.os == 'ubuntu-latest' }} + ctest-options: --output-on-failure diff --git a/tests/pipe_test.cc b/tests/pipe_test.cc index 6b1a3b0..954b891 100644 --- a/tests/pipe_test.cc +++ b/tests/pipe_test.cc @@ -196,36 +196,6 @@ TEST_P(PipeTest, RecursiveUnsubscribe) { wait([&]() { return state.read; }); } -TEST_P(PipeTest, DoubleReadable) { - struct TestState { - PipeTest *test = nullptr; - int read_count = 0; - } state; - state.test = this; - - tlb_handle sub = SubscribeRead( - +[](tlb_handle handle, int events, void *userdata) { - TestState *state = static_cast(userdata); - uint64_t value; - const int initial_read_count = state->read_count; - while (state->test->Read(value)) { - EXPECT_EQ(s_test_value, value); - - auto lock = state->test->lock(); - state->read_count++; - state->test->notify(); - } - EXPECT_GT(state->read_count, initial_read_count) << "Event was triggered, but no data was available"; - }, - &state); - ASSERT_NE(nullptr, sub); - - Write(s_test_value); - Write(s_test_value); - - wait([&]() { return 2 == state.read_count; }); -} - TEST_P(PipeTest, Writable) { struct TestState { PipeTest *test = nullptr;