Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Code climate: fix next batch of "; " occurences
  • Loading branch information
stanislaw committed Dec 5, 2021
commit f3fce93c1e8db7db18b923d31ac2ede157345834
Original file line number Diff line number Diff line change
@@ -1 +1 @@
; CHECK: hello
CHECK: hello
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
; RUN: echo "hello" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --match-full-lines
RUN: echo "hello" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --match-full-lines

; RUN: echo " hello" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --match-full-lines
RUN: echo " hello" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --match-full-lines

; RUN: echo " hello" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --match-full-lines
RUN: echo " hello" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --match-full-lines

; RUN: echo "hello " | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --match-full-lines
RUN: echo "hello " | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --match-full-lines

; RUN: echo "hello " | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --match-full-lines
RUN: echo "hello " | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --match-full-lines
Original file line number Diff line number Diff line change
@@ -1 +1 @@
; CHECK: hello world hello world
CHECK: hello world hello world
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
; RUN: %cat "%S/filecheck.input" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check"
; RUN: %cat "%S/filecheck.input" | %expect_exit 1 %FILECHECK_EXEC "%S/filecheck.check" --strict-whitespace | %FILECHECK_TESTER_EXEC "%s" --match-full-lines --check-prefix=OPTION
RUN: %cat "%S/filecheck.input" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check"
RUN: %cat "%S/filecheck.input" | %expect_exit 1 %FILECHECK_EXEC "%S/filecheck.check" --strict-whitespace | %FILECHECK_TESTER_EXEC "%s" --match-full-lines --check-prefix=OPTION

; OPTION: {{^.*}}filecheck.check:1:10: error: CHECK: expected string not found in input{{$}}
; OPTION: ; CHECK: hello world hello world
; OPTION: ^
; OPTION: {{^<stdin>:.*:.*: note: scanning from here$}}
; OPTION: hello world hello world
; OPTION: {{^\^$}}
; TODO: error: OPTION-EMPTY is not on the line after the previous match
; OPTION-EMPTY
OPTION: {{^.*}}filecheck.check:1:8: error: CHECK: expected string not found in input{{$}}
OPTION: CHECK: hello world hello world
OPTION: ^
OPTION: {{^<stdin>:.*:.*: note: scanning from here$}}
OPTION: hello world hello world
OPTION: {{^\^$}}
TODO: error: OPTION-EMPTY is not on the line after the previous match
OPTION-EMPTY
Original file line number Diff line number Diff line change
@@ -1 +1 @@
; CHECK: hello world hello world
CHECK: hello world hello world
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
; RUN: %cat "%S/filecheck.input" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check"
; RUN: %cat "%S/filecheck.input" | %expect_exit 1 %FILECHECK_EXEC "%S/filecheck.check" --strict-whitespace | %FILECHECK_TESTER_EXEC "%s" --strict-whitespace --match-full-lines --check-prefix=OPTION
RUN: %cat "%S/filecheck.input" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check"
RUN: %cat "%S/filecheck.input" | %expect_exit 1 %FILECHECK_EXEC "%S/filecheck.check" --strict-whitespace | %FILECHECK_TESTER_EXEC "%s" --strict-whitespace --match-full-lines --check-prefix=OPTION

; OPTION:{{^.*}}filecheck.check:1:10: error: CHECK: expected string not found in input{{$}}
; OPTION:; CHECK: hello world hello world
; OPTION: ^
; OPTION:{{^<stdin>:.*:.*: note: scanning from here$}}
; OPTION:hello world hello world
; OPTION:^
; TODO: error: OPTION-EMPTY is not on the line after the previous match
; OPTION-EMPTY
OPTION:{{^.*}}filecheck.check:1:8: error: CHECK: expected string not found in input{{$}}
OPTION:CHECK: hello world hello world
OPTION: ^
OPTION:{{^<stdin>:.*:.*: note: scanning from here$}}
OPTION:hello world hello world
OPTION:^
TODO: error: OPTION-EMPTY is not on the line after the previous match
OPTION-EMPTY
Original file line number Diff line number Diff line change
@@ -1 +1 @@
; CHECK-NOT: hello world hello world
CHECK-NOT: hello world hello world
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
; RUN: %cat "%S/filecheck.input" | %expect_exit 1 %FILECHECK_EXEC "%S/filecheck.check" | %FILECHECK_TESTER_EXEC "%s" --strict-whitespace --match-full-lines --check-prefix=NO_OPTION
; RUN: %cat "%S/filecheck.input" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --strict-whitespace
RUN: %cat "%S/filecheck.input" | %expect_exit 1 %FILECHECK_EXEC "%S/filecheck.check" | %FILECHECK_TESTER_EXEC "%s" --strict-whitespace --match-full-lines --check-prefix=NO_OPTION
RUN: %cat "%S/filecheck.input" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check" --strict-whitespace

; NO_OPTION:{{^.*}}filecheck.check:1:14: error: CHECK-NOT: excluded string found in input{{$}}
; NO_OPTION:; CHECK-NOT: hello world hello world
; NO_OPTION: ^
; NO_OPTION:{{^<stdin>:.:.: note: found here$}}
; NO_OPTION:hello world hello world
; NO_OPTION:^~~~~~~~~~~~~~~~~~~~~~~
; NO_OPTION-EMPTY:
NO_OPTION:{{^.*}}filecheck.check:1:12: error: CHECK-NOT: excluded string found in input{{$}}
NO_OPTION:CHECK-NOT: hello world hello world
NO_OPTION: ^
NO_OPTION:{{^<stdin>:.:.: note: found here$}}
NO_OPTION:hello world hello world
NO_OPTION:^~~~~~~~~~~~~~~~~~~~~~~
NO_OPTION-EMPTY:
Original file line number Diff line number Diff line change
@@ -1 +1 @@
; CHECK: hello world hello world
CHECK: hello world hello world
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
; RUN: %cat "%S/filecheck.input" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check"
; RUN: %cat "%S/filecheck.input" | %expect_exit 1 %FILECHECK_EXEC "%S/filecheck.check" --strict-whitespace | %FILECHECK_TESTER_EXEC "%s" --strict-whitespace --match-full-lines --check-prefix=OPTION
RUN: %cat "%S/filecheck.input" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check"
RUN: %cat "%S/filecheck.input" | %expect_exit 1 %FILECHECK_EXEC "%S/filecheck.check" --strict-whitespace | %FILECHECK_TESTER_EXEC "%s" --strict-whitespace --match-full-lines --check-prefix=OPTION

; OPTION:{{^.*}}filecheck.check:1:10: error: CHECK: expected string not found in input{{$}}
; OPTION:; CHECK: hello world hello world
; OPTION: ^
; OPTION:{{^<stdin>:.*:.*: note: scanning from here$}}
; OPTION:hello world hello world
; OPTION:^
; TODO: error: OPTION-EMPTY is not on the line after the previous match
; OPTION-EMPTY
OPTION:{{^.*}}filecheck.check:1:8: error: CHECK: expected string not found in input{{$}}
OPTION:CHECK: hello world hello world
OPTION: ^
OPTION:{{^<stdin>:.*:.*: note: scanning from here$}}
OPTION:hello world hello world
OPTION:^
TODO: error: OPTION-EMPTY is not on the line after the previous match
OPTION-EMPTY
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
; CHECK: foo
; CHECK-EMPTY:
; CHECK-NEXT: bar
CHECK: foo
CHECK-EMPTY:
CHECK-NEXT: bar
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
/**
; RUN: cd / && %CLANG_EXEC -fembed-bitcode -g -O0 -MJ %S/raw_compilation_database.tmp %s -o %s.exe
; RUN: cd %CURRENT_DIR
; RUN: compilation_database.sh %S/raw_compilation_database.tmp %S/compile_commands.tmp
; RUN: compilation_database.py %S/compile_commands.tmp %S/compile_commands.json
; RUN: %MULL_EXEC -enable-ast -test-framework CustomTest -compdb-path %S/compile_commands.json -compilation-flags="" -mutators=scalar_value_mutator -reporters=IDE -reporters=Elements -report-dir=%S -report-name=report %s.exe| %FILECHECK_EXEC %s --strict-whitespace
; CHECK-NOT: No mutants found. Mutation score: infinitely high
; CHECK: Running mutants (threads: 1): 0/1{{.*$}}
; CHECK: {{.*}}:17:3: warning: Replacing scalar with 0 or 42
; CHECK: {{^ }}return SUCCESS;{{$}}
; CHECK: {{^ }}^{{$}}
RUN: cd / && %CLANG_EXEC -fembed-bitcode -g -O0 -MJ %S/raw_compilation_database.tmp %s -o %s.exe
RUN: cd %CURRENT_DIR
RUN: compilation_database.sh %S/raw_compilation_database.tmp %S/compile_commands.tmp
RUN: compilation_database.py %S/compile_commands.tmp %S/compile_commands.json
RUN: %MULL_EXEC -enable-ast -test-framework CustomTest -compdb-path %S/compile_commands.json -compilation-flags="" -mutators=scalar_value_mutator -reporters=IDE -reporters=Elements -report-dir=%S -report-name=report %s.exe| %FILECHECK_EXEC %s --strict-whitespace
CHECK-NOT: No mutants found. Mutation score: infinitely high
CHECK: Running mutants (threads: 1): 0/1{{.*$}}
CHECK: {{.*}}:17:3: warning: Replacing scalar with 0 or 42
CHECK: {{^ }}return SUCCESS;{{$}}
CHECK: {{^ }}^{{$}}
**/

enum Enum { SUCCESS = 1234 };
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
/**
; RUN: cd / && %CLANG_EXEC -fembed-bitcode -g -O0 %s -o %s.exe
; RUN: cd %CURRENT_DIR
RUN: cd / && %CLANG_EXEC -fembed-bitcode -g -O0 %s -o %s.exe
RUN: cd %CURRENT_DIR

/// IDEReporter is enabled by default. So we test both invocations of mull-cxx:
/// 1) when -reporters=IDE is not provided
/// 2) when -reporters=IDE is provided

; RUN: (unset TERM; %MULL_EXEC -test-framework CustomTest -mutators=cxx_add_to_sub %s.exe | %FILECHECK_EXEC %s --strict-whitespace --match-full-lines --check-prefix=WITHOUT-OPTION)
; RUN: (unset TERM; %MULL_EXEC -test-framework CustomTest -mutators=cxx_add_to_sub -reporters=IDE %s.exe | %FILECHECK_EXEC %s --strict-whitespace --match-full-lines --check-prefix=WITHOUT-OPTION)
RUN: (unset TERM; %MULL_EXEC -test-framework CustomTest -mutators=cxx_add_to_sub %s.exe | %FILECHECK_EXEC %s --strict-whitespace --match-full-lines --check-prefix=WITHOUT-OPTION)
RUN: (unset TERM; %MULL_EXEC -test-framework CustomTest -mutators=cxx_add_to_sub -reporters=IDE %s.exe | %FILECHECK_EXEC %s --strict-whitespace --match-full-lines --check-prefix=WITHOUT-OPTION)
; WITHOUT-OPTION:{{^Running mutants \(threads: 2\): 2\/2.*$}}
; WITHOUT-OPTION:Survived mutants (1/2):
; WITHOUT-OPTION-EMPTY:
Expand All @@ -18,8 +18,8 @@
; WITHOUT-OPTION-NEXT:Mutation score: 50%
; WITHOUT-OPTION-EMPTY:

; RUN: (unset TERM; %MULL_EXEC -test-framework CustomTest -mutators=cxx_add_to_sub -ide-reporter-show-killed %s.exe | %FILECHECK_EXEC %s --strict-whitespace --match-full-lines --check-prefix=WITH-OPTION)
; RUN: (unset TERM; %MULL_EXEC -test-framework CustomTest -mutators=cxx_add_to_sub -reporters=IDE -ide-reporter-show-killed %s.exe | %FILECHECK_EXEC %s --strict-whitespace --match-full-lines --check-prefix=WITH-OPTION)
RUN: (unset TERM; %MULL_EXEC -test-framework CustomTest -mutators=cxx_add_to_sub -ide-reporter-show-killed %s.exe | %FILECHECK_EXEC %s --strict-whitespace --match-full-lines --check-prefix=WITH-OPTION)
RUN: (unset TERM; %MULL_EXEC -test-framework CustomTest -mutators=cxx_add_to_sub -reporters=IDE -ide-reporter-show-killed %s.exe | %FILECHECK_EXEC %s --strict-whitespace --match-full-lines --check-prefix=WITH-OPTION)
; WITH-OPTION:{{^Running mutsants \(threads: 2\): 2\/2.*$}}
; WITH-OPTION:Killed mutants (1/2):
; WITH-OPTION-EMPTY:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
; RUN: %cat "%S/filecheck.input" | %expect_exit 1 %FILECHECK_EXEC "%S/filecheck.check" --strict-whitespace --match-full-lines --check-prefix=WITH-OPTION | %FILECHECK_TESTER_EXEC "%s" --strict-whitespace --match-full-lines
RUN: %cat "%S/filecheck.input" | %expect_exit 1 %FILECHECK_EXEC "%S/filecheck.check" --strict-whitespace --match-full-lines --check-prefix=WITH-OPTION | %FILECHECK_TESTER_EXEC "%s" --strict-whitespace --match-full-lines

; CHECK:{{^.*}}filecheck.check:23:15: error: WITH-OPTION: expected string not found in input
; CHECK-NEXT:{{^; WITH-OPTION:..\^Running mutsants \\\(threads: 2\\\): 2\\\/2\.\*\$..$}}
; CHECK-NEXT:{{^ \^$}}
; CHECK-NEXT:<stdin>:2:1: note: scanning from here
; CHECK-NEXT:Extracting bitcode from executable (threads: 1): 0/1
; CHECK-NEXT:^
CHECK:{{^.*}}filecheck.check:23:15: error: WITH-OPTION: expected string not found in input
CHECK-NEXT:{{^; WITH-OPTION:..\^Running mutsants \\\(threads: 2\\\): 2\\\/2\.\*\$..$}}
CHECK-NEXT:{{^ \^$}}
CHECK-NEXT:<stdin>:2:1: note: scanning from here
CHECK-NEXT:Extracting bitcode from executable (threads: 1): 0/1
CHECK-NEXT:^
; TODO: Again, the "note: possible intended match here" feature needs revision, #38
; TODO: https://github.com/stanislaw/FileCheck.py/issues/38.
; TODO: Doing (1|17) and ".*\^" for now.
; CHECK-NEXT:<stdin>:59:{{(1|17)}}: note: possible intended match here
; CHECK-NEXT:Running mutants (threads: 2): 0/2
; CHECK-NEXT:{{^.*\^$}}
; CHECK-EMPTY:
CHECK-NEXT:<stdin>:59:{{(1|17)}}: note: possible intended match here
CHECK-NEXT:Running mutants (threads: 2): 0/2
CHECK-NEXT:{{^.*\^$}}
CHECK-EMPTY: