distortos  v0.5.0
object-oriented C++ RTOS for microcontrollers
SignalsCatchingTestCase.cpp File Reference

SignalsCatchingTestCase class implementation. More...

Include dependency graph for SignalsCatchingTestCase.cpp:

Classes

struct  distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::Stage
 single test stage More...
 
class  distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::BasicHandlerStep
 basic type of test step executed in signal handler More...
 
class  distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::GenerateQueueSignalStep
 test step that generates or queues a signal More...
 
class  distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::ThreadPriorityStep
 test step that changes thread's priority More...
 
class  distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::SignalMaskStep
 test step that sets signal mask More...
 
class  distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::SoftwareTimerStep
 test step that creates software timer, starts it and waits until it stops More...
 
class  distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::TestStep
 single test step More...
 

Namespaces

 distortos
 Top-level namespace of distortos project.
 
 distortos::test
 Functional tests of distortos project.
 

Macros

#define SIGNALS_CATCHING_TEST_CASE_ENABLED
 configuration required by SignalsCatchingTestCase More...
 

Typedefs

using distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::TestStepsRange = estd::ContiguousRange< const TestStep >
 range of test steps More...
 
using distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::SequencePoints = std::pair< unsigned int, unsigned int >
 pair of sequence points More...
 

Functions

constexpr SignalSet distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::getSignalMask (const uint8_t signalNumber)
 Generates special test pattern of signal mask. More...
 
void distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::testStepsRunner (TestStepsRange &testStepsRange, Thread &thread, const SignalInformation *const signalInformation)
 Runner of test steps. More...
 
void distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::handler (const SignalInformation &signalInformation)
 Signal handler. More...
 

Variables

constexpr auto distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::mainTestThreadPriority = SignalsCatchingTestCase::getTestCasePriority()
 original priority of main test thread More...
 
decltype(mainTestThreadPriority) constexpr distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::secondTestThreadPriority {mainTestThreadPriority - 1}
 priority of second test thread - just below mainTestThreadPriority More...
 
decltype(mainTestThreadPriority) constexpr distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::lowPriority {secondTestThreadPriority - 1}
 low priority of main test thread - just below secondTestThreadPriority More...
 
constexpr size_t distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::secondTestThreadStackSize {512}
 size of stack for second test thread, bytes More...
 
constexpr size_t distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::totalSignals {8}
 total number of signals that are tested More...
 
TestStepsRange distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::handlerStepsRange
 range of test steps for signal handler More...
 
sig_atomic_t distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::sharedSigAtomic
 shared return code of signal handler, is is reset before each test phase More...
 
SequenceAsserter distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::sharedSequenceAsserter
 shared SequenceAsserter object, is is reset before each test phase More...
 
const TestStep distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::phase1MainTestThreadSteps []
 test steps for first phase, for main test thread More...
 
const TestStep distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::phase1SignalHandlerSteps []
 test steps for first phase, for signal handler More...
 
const TestStep distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::phase2MainTestThreadSteps []
 test steps for second phase, for main test thread More...
 
const TestStep distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::phase2SignalHandlerSteps []
 test steps for second phase, for signal handler More...
 
const TestStep distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::phase3MainTestThreadSteps []
 test steps for third phase, for main test thread More...
 
const TestStep distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::phase3SignalHandlerSteps []
 test steps for third phase, for signal handler More...
 
const TestStep distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::phase3SecondTestThreadStepsRange []
 test steps for third phase, for second test thread More...
 
const Stage distortos::test::anonymous_namespace{SignalsCatchingTestCase.cpp}::stages []
 test stages More...
 

Detailed Description

SignalsCatchingTestCase class implementation.

Author
Copyright (C) 2015-2017 Kamil Szczygiel http://www.distortec.com http://www.freddiechopin.info
License
This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.

Macro Definition Documentation

◆ SIGNALS_CATCHING_TEST_CASE_ENABLED

#define SIGNALS_CATCHING_TEST_CASE_ENABLED
Value:
CONFIG_SIGNALS_ENABLE == 1 && CONFIG_MAIN_THREAD_QUEUED_SIGNALS >= 8 && \
CONFIG_MAIN_THREAD_SIGNAL_ACTIONS >= 8

configuration required by SignalsCatchingTestCase