Skip to content

Commit

Permalink
make test handle .c.v as well as .v
Browse files Browse the repository at this point in the history
  • Loading branch information
JalonSolov committed Nov 19, 2023
1 parent aae5331 commit c120e2e
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion vlib/v/slow_tests/valgrind/valgrind_test.v
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,12 @@ fn test_all() {
}
}
//
base_filename := os.file_name(test).replace('.v', '')
mut base_filename := os.file_name(test)
if base_filename.ends_with('.c.v') {
base_filename = base_filename#[..-4]
} else if base_filename.ends_with('.v') {
base_filename = base_filename#[..-2]
}
exe_filename := '${wrkdir}/${base_filename}'
full_path_to_source_file := os.join_path(vroot, test)
compile_cmd := '${os.quoted_path(vexe)} -o ${os.quoted_path(exe_filename)} -cg -cflags ' +
Expand Down

0 comments on commit c120e2e

Please sign in to comment.