|
1 | 1 | // Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries. |
2 | 2 | // SPDX-License-Identifier: BSD-3-Clause-Clear |
3 | 3 |
|
4 | | -#include "ErrCodes.h" |
5 | | -#include "UrmPlatformAL.h" |
| 4 | +#include <thread> |
| 5 | + |
6 | 6 | #include "Utils.h" |
7 | | -#include "TestUtils.h" |
8 | | -#include "URMTests.h" |
9 | 7 | #include "UrmAPIs.h" |
10 | | -#include <thread> |
| 8 | +#include "ErrCodes.h" |
| 9 | +#include "URMTests.h" |
| 10 | +#include "TestUtils.h" |
| 11 | +#include "UrmPlatformAL.h" |
11 | 12 |
|
12 | 13 | // Test configuration and paths |
13 | 14 | #define TEST_CLASS "INTEGRATION" |
|
17 | 18 | // Path to the Floret supervised learning model binary |
18 | 19 | static const std::string FT_MODEL_PATH = CLASSIFIER_CONFIGS_DIR "floret_model_supervised.bin"; |
19 | 20 |
|
20 | | - |
21 | 21 | /** |
22 | 22 | * API under test: Tune / Untune |
23 | 23 | * - Spawns GStreamer and verifies that correctly |
@@ -45,16 +45,16 @@ URM_TEST(TestGstreamerPerAppConfigValidated, { |
45 | 45 |
|
46 | 46 | // Verify executable exists before attempting spawn |
47 | 47 | if (!AuxRoutines::fileExists("/usr/bin/gst-launch-1.0")) { |
48 | | - std::cout << LOG_BASE << "Executable not found: /usr/bin/gst-launch-1.0" << std::endl; |
49 | | - std::cout << LOG_BASE << "Status: SKIPPED" << std::endl; |
| 48 | + LOG_SKIP("Executable not found: /usr/bin/gst-launch-1.0"); |
| 49 | + SKIP; |
50 | 50 | return; |
51 | 51 | } |
52 | 52 |
|
53 | 53 | // Spawn GStreamer |
54 | 54 | pid_t pid = fork(); |
55 | 55 | if (pid == 0) { |
56 | 56 | // Child process: redirect output to suppress application noise |
57 | | - int devNull = open("/dev/null", O_WRONLY); |
| 57 | + int32_t devNull = open("/dev/null", O_WRONLY); |
58 | 58 | if (devNull != -1) { |
59 | 59 | dup2(devNull, STDERR_FILENO); |
60 | 60 | dup2(devNull, STDOUT_FILENO); |
@@ -128,18 +128,15 @@ URM_TEST(TestViPerAppConfigValidated, { |
128 | 128 |
|
129 | 129 | // Verify executable exists before attempting spawn |
130 | 130 | if (!AuxRoutines::fileExists("/usr/bin/vi")) { |
131 | | - std::cout << LOG_BASE << "Executable not found: " <<"/usr/bin/vi"<< std::endl; |
132 | | - std::cout << LOG_BASE << "Status: SKIPPED" << std::endl; |
133 | | - |
134 | | - // return from this Test case if not .exe not exist |
135 | | - return; |
| 131 | + LOG_SKIP("Executable not found: /usr/bin/vi"); |
| 132 | + SKIP; |
136 | 133 | } |
137 | 134 |
|
138 | 135 | // Spawn vi |
139 | 136 | pid_t pid = fork(); |
140 | 137 | if (pid == 0) { |
141 | 138 | // Child process: redirect output to suppress application noise |
142 | | - int devNull = open("/dev/null", O_WRONLY); |
| 139 | + int32_t devNull = open("/dev/null", O_WRONLY); |
143 | 140 | if (devNull != -1) { |
144 | 141 | dup2(devNull, STDERR_FILENO); |
145 | 142 | dup2(devNull, STDOUT_FILENO); |
|
0 commit comments