summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/slang-test/slang-test-main.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/tools/slang-test/slang-test-main.cpp b/tools/slang-test/slang-test-main.cpp
index 351875aeb..87441c6c4 100644
--- a/tools/slang-test/slang-test-main.cpp
+++ b/tools/slang-test/slang-test-main.cpp
@@ -575,6 +575,13 @@ static SlangResult _gatherTestsForFile(
continue;
}
+ // Skip any extra slashes and spaces to handle malformed directives like ///TEST or // TEST
+ while (*cursor == '/')
+ {
+ cursor++;
+ }
+ skipHorizontalSpace(&cursor);
+
UnownedStringSlice command;
if (SLANG_FAILED(_extractCommand(&cursor, command)))