MCPcopy Create free account
hub / github.com/WiringPi/WiringPi / TEST_F

Function TEST_F

wiringPi/gtest/test_isr_conflict_between_processes.cpp:56–68  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

54uint32_t ISRConflict::count = 0;
55
56TEST_F(ISRConflict, TestConflictBetweenProcesses) {
57 // The ISRs should fail to start because run_isr is listening on the
58 // same port
59 EXPECT_EQ(
60 wiringPiISR(LISTENER_PIN, INT_EDGE_FALLING, ISRConflict::TriggerCount),
61 -1);
62 EXPECT_EQ(wiringPiISR2(LISTENER_PIN, INT_EDGE_FALLING,
63 ISRConflict::TriggerCount2, 0, &ISRConflict::count),
64 -1);
65
66 // to exit run_isr
67 digitalWrite(TRIGGER_PIN, HIGH);
68}

Callers

nothing calls this directly

Calls 3

wiringPiISRFunction · 0.85
wiringPiISR2Function · 0.85
digitalWriteFunction · 0.85

Tested by

no test coverage detected