File tree Expand file tree Collapse file tree
.github/workflows/test_scripts Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -18,16 +18,19 @@ def find_all_cpp_files(findWorking):
1818
1919
2020def test_single_cpp_file (file_path , shouldCompile ):
21- compile_status = subprocess .getoutput (f"g++ { file_path } " )
21+ compile_status = subprocess .getoutput (f"g++ { file_path } -w " )
2222
23- if (compile_status != "" and shouldCompile ) or (
24- compile_status == "" and not shouldCompile
25- ):
23+ if compile_status != "" and shouldCompile :
2624 print ("\n " + 20 * "=" )
2725 print (f"Error in file { file_path } :\n " )
2826 print (compile_status )
2927 print (20 * "=" + "\n " )
3028 return False
29+ elif compile_status == "" and not shouldCompile :
30+ print ("\n " + 20 * "=" )
31+ print (f"File { file_path } compiles, but should be broken" )
32+ print ("\n " + 20 * "=" )
33+ return False
3134
3235 return True
3336
Original file line number Diff line number Diff line change 1- #include < iostream>
2-
31int main () {
42 std::cout << " Hello world" << std::endl;
53
You can’t perform that action at this time.
0 commit comments