INSTINCT Code Coverage Report


Directory: src/
File: Nodes/Utility/Terminator.cpp
Date: 2025-11-25 23:34:18
Exec Total Coverage
Lines: 14 16 87.5%
Functions: 5 6 83.3%
Branches: 8 16 50.0%

Line Branch Exec Source
1 // This file is part of INSTINCT, the INS Toolkit for Integrated
2 // Navigation Concepts and Training by the Institute of Navigation of
3 // the University of Stuttgart, Germany.
4 //
5 // This Source Code Form is subject to the terms of the Mozilla Public
6 // License, v. 2.0. If a copy of the MPL was not distributed with this
7 // file, You can obtain one at https://mozilla.org/MPL/2.0/.
8
9 #include "Terminator.hpp"
10
11 #include "internal/FlowManager.hpp"
12
13 // ---------------------------------------------------------- Member functions -------------------------------------------------------------
14
15
2/4
✓ Branch 1 taken 163 times.
✗ Branch 2 not taken.
✓ Branch 4 taken 163 times.
✗ Branch 5 not taken.
163 NAV::Terminator::Terminator() : Node(typeStatic())
16 {
17 LOG_TRACE("{}: called", name);
18 163 _hasConfig = false;
19 163 kind = Kind::Simple;
20
21
4/8
✓ Branch 1 taken 163 times.
✗ Branch 2 not taken.
✓ Branch 5 taken 163 times.
✗ Branch 6 not taken.
✓ Branch 8 taken 163 times.
✓ Branch 9 taken 163 times.
✗ Branch 12 not taken.
✗ Branch 13 not taken.
489 CreateInputPin("", Pin::Type::Flow, { NodeData::type() }, &Terminator::receiveObs);
22 326 }
23
24 420 NAV::Terminator::~Terminator()
25 {
26 LOG_TRACE("{}: called", nameId());
27 420 }
28
29 277 std::string NAV::Terminator::typeStatic()
30 {
31
1/2
✓ Branch 1 taken 277 times.
✗ Branch 2 not taken.
554 return "Terminator";
32 }
33
34 std::string NAV::Terminator::type() const
35 {
36 return typeStatic();
37 }
38
39 114 std::string NAV::Terminator::category()
40 {
41
1/2
✓ Branch 1 taken 114 times.
✗ Branch 2 not taken.
228 return "Utility";
42 }
43
44 6333 void NAV::Terminator::receiveObs(NAV::InputPin::NodeDataQueue& queue, size_t /* pinIdx */) // NOLINT(readability-convert-member-functions-to-static)
45 {
46 6333 queue.pop_front();
47 6333 }
48