Debian Codegraph @

tests/src/test_noop.cpp

raw symbols SCIP
1 // SPDX-License-Identifier: GPL-3.0-or-latercxx . . $ `<file>/tests/src/test_noop.cpp`/
2 // Copyright 2021 Juan Palacios <[email protected]>
3
4 #include <catch2/catch_all.hpp>
5
6 #include "common/commandqueuestub.h"cxx . . $ `<file>/tests/src/common/commandqueuestub.h`/
7 #include "core/components/controls/noop.h"cxx . . $ `<file>/src/core/components/controls/noop.h`/
8
9 namespace Testscxx . . $ Tests/::Noopcxx . . $ Tests/Noop/ {
10
11 class NoopTestAdaptercxx . . $ Tests/Noop/NoopTestAdapter# : public ::Noopcxx . . $ Noop#
12 {
13 public:
14 using ::Noopcxx . . $ Noop#::Noopcxx . . $ Tests/Noop/NoopTestAdapter#NoopTestAdapter(fed5b3c47d1b2a3e).;
15
16 using ::Noopcxx . . $ Noop#::cleanControlcxx . . $ Tests/Noop/NoopTestAdapter#cleanControl(151e9138769f295e).;
17 using ::Noopcxx . . $ Noop#::syncControlcxx . . $ Tests/Noop/NoopTestAdapter#syncControl(151e9138769f295e).;
18 };
19
20 TEST_CASEcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:144:11`!("Noop control tests", "[Noop]")
21 {
22 CommandQueueStubcxx . . $ CommandQueueStub# ctlCmds;
23
24 SECTIONcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:149:11`!("Has Noop ID")
25 {
26 NoopTestAdaptercxx . . $ Tests/Noop/NoopTestAdapter# ts;
27
28 REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(ts.ID() == ::Noop::ItemID);
29 }
30
31 SECTIONcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:149:11`!("Is active by default")
32 {
33 NoopTestAdaptercxx . . $ Tests/Noop/NoopTestAdapter# ts;
34
35 REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(ts.active());
36 }
37
38 SECTIONcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:149:11`!("Does not generate pre-init control commands")
39 {
40 NoopTestAdaptercxx . . $ Tests/Noop/NoopTestAdapter# ts;
41 ts.preInitcxx . . $ Noop#preInit(151e9138769f295e).(ctlCmds);
42
43 REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(ctlCmds.commands().empty());
44 }
45
46 SECTIONcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:149:11`!("Does not generate post-init control commands")
47 {
48 NoopTestAdaptercxx . . $ Tests/Noop/NoopTestAdapter# ts;
49 ts.postInitcxx . . $ Noop#postInit(151e9138769f295e).(ctlCmds);
50
51 REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(ctlCmds.commands().empty());
52 }
53
54 SECTIONcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:149:11`!("Does not generate clean control commands")
55 {
56 NoopTestAdaptercxx . . $ Tests/Noop/NoopTestAdapter# ts;
57 ts.cleanControlcxx . . $ Noop#cleanControl(151e9138769f295e).(ctlCmds);
58
59 REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(ctlCmds.commands().empty());
60 }
61
62 SECTIONcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:149:11`!("Does not generate sync control commands")
63 {
64 NoopTestAdaptercxx . . $ Tests/Noop/NoopTestAdapter# ts;
65 ts.syncControlcxx . . $ Noop#syncControl(151e9138769f295e).(ctlCmds);
66
67 REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(ctlCmds.commands().empty());
68 }
69 }
70
71 } // namespace Tests::Noop