distortos  v0.5.0
object-oriented C++ RTOS for microcontrollers
distortos::test::anonymous_namespace{SignalsInterruptionTestCase.cpp}::SignalsTestStep Class Reference

test step for waiting for signals More...

Inheritance diagram for distortos::test::anonymous_namespace{SignalsInterruptionTestCase.cpp}::SignalsTestStep:
Collaboration diagram for distortos::test::anonymous_namespace{SignalsInterruptionTestCase.cpp}::SignalsTestStep:

Public Types

enum  Type : uint8_t { Type::wait, Type::tryWaitFor, Type::tryWaitUntil }
 type of signals test step More...

Public Member Functions

constexpr SignalsTestStep (const Type type)
 SignalsTestStep's constructor. More...
- Public Member Functions inherited from distortos::test::anonymous_namespace{SignalsInterruptionTestCase.cpp}::TestStep
constexpr TestStep (const uint8_t totalSequencePoints, const uint8_t expectedContextSwitchCount, const uint8_t signalingThreadSequencePoint1, const uint8_t signalHandlerSequencePoint, const uint8_t joinSequencePoint, const uint8_t signalingThreadSequencePoint2)
 TestStep's constructor. More...
virtual ~TestStep ()
 TestStep's virtual destructor. More...
bool run (SequenceAsserter &sequenceAsserter)
 Runs test step. More...
std::pair< uint8_t, uint8_t > getParameters () const
 Gets execution parameters of test step. More...

Private Member Functions

bool block () override
 Executes the action that will block current thread. More...

Private Attributes

Type type_
 type of test step More...

Detailed Description

test step for waiting for signals

Member Enumeration Documentation

◆ Type

enum distortos::test::anonymous_namespace{SignalsInterruptionTestCase.cpp}::SignalsTestStep::Type : uint8_t

type of signals test step


uses ThisThread::Signals::wait()


uses ThisThread::Signals::tryWaitFor()


uses ThisThread::Signals::tryWaitUntil()

Constructor & Destructor Documentation

◆ SignalsTestStep()

constexpr distortos::test::anonymous_namespace{SignalsInterruptionTestCase.cpp}::SignalsTestStep::SignalsTestStep ( const Type  type)

SignalsTestStep's constructor.

[in]typeis the type of test step

Member Function Documentation

◆ block()

bool distortos::test::anonymous_namespace{SignalsInterruptionTestCase.cpp}::SignalsTestStep::block ( )

Executes the action that will block current thread.

Calls ThisThread::Signals::wait(), ThisThread::Signals::tryWaitFor() or ThisThread::Signals::tryWaitUntil() - depending on the type of test step - and ensures that the function returns with EINTR error code.

true if execution of blocking action succeeded, false otherwise

Implements distortos::test::anonymous_namespace{SignalsInterruptionTestCase.cpp}::TestStep.

Here is the call graph for this function:

Member Data Documentation

◆ type_

Type distortos::test::anonymous_namespace{SignalsInterruptionTestCase.cpp}::SignalsTestStep::type_

type of test step

The documentation for this class was generated from the following file: