Skip to content

Commit cbdda2d

Browse files
committed
Address comments
1 parent 41b6377 commit cbdda2d

1 file changed

Lines changed: 12 additions & 1 deletion

File tree

test/test-rosidl-message-generator.js

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,17 @@ function sourceSetupScript(setupPath) {
6363
function buildTestMessage() {
6464
// Build the custom_msg_test package synchronously before running the test
6565
const customMsgTestPath = path.join(__dirname, 'custom_msg_test');
66+
67+
// List packages to ensure colcon can discover them
68+
require('child_process').spawnSync(
69+
'colcon',
70+
['--log-base', '/dev/null', 'list'],
71+
{
72+
cwd: customMsgTestPath,
73+
stdio: 'inherit',
74+
}
75+
);
76+
6677
const buildResult = require('child_process').spawnSync('colcon', ['build'], {
6778
cwd: customMsgTestPath,
6879
stdio: 'inherit',
@@ -77,7 +88,7 @@ function buildTestMessage() {
7788

7889
if (buildResult.status !== 0) {
7990
console.log(buildResult);
80-
// throw new Error(`colcon build failed with exit code ${buildResult.status}`);
91+
throw new Error(`colcon build failed with exit code ${buildResult.status}`);
8192
}
8293

8394
// Source the local_setup.sh to get environment variables

0 commit comments

Comments
 (0)