Skip to content

Commit a51a172

Browse files
committed
Make a few tests independent of the default diagnostic style
1 parent 8ed35de commit a51a172

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

test/CAS/educational-notes.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
// RUN: not %target-swift-frontend -color-diagnostics -diagnostic-style=llvm -print-educational-notes -diagnostic-documentation-path %S/../diagnostics/test-docs/ \
1313
// RUN: -emit-module -emit-module-path %t/test.module @%t/MyApp.cmd %s 2>&1 | %FileCheck %s --match-full-lines --strict-whitespace
14-
// RUN: not %target-swift-frontend -no-color-diagnostics -print-educational-notes -diagnostic-documentation-path %S/../diagnostics/test-docs/ \
14+
// RUN: not %target-swift-frontend -no-color-diagnostics -diagnostic-style=llvm -print-educational-notes -diagnostic-documentation-path %S/../diagnostics/test-docs/ \
1515
// RUN: -emit-module -emit-module-path %t/test.module @%t/MyApp.cmd %s 2>&1 | %FileCheck %s --match-full-lines --strict-whitespace --check-prefix=NO-COLOR
1616

1717
// A diagnostic with no educational notes

test/decl/enum/objc_enum_multi_file.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@
3535
case A
3636
case B = 0
3737
// DUPLICATE_CASES: :[[@LINE-1]]:12: error: raw value for enum case is not unique
38-
// DUPLICATE_CASES: :[[@LINE-3]]:8: note: raw value previously used here
39-
// DUPLICATE_CASES: :[[@LINE-4]]:8: note: raw value implicitly auto-incremented from zero
38+
// DUPLICATE_CASES: note: raw value previously used here
39+
// DUPLICATE_CASES: note: raw value implicitly auto-incremented from zero
4040
}
4141

4242
#elseif NON_INT_RAW_VALUE

test/diagnostics/educational-notes.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
// RUN: not %target-swift-frontend -color-diagnostics -diagnostic-style=llvm -print-educational-notes -diagnostic-documentation-path %S/test-docs/ -typecheck %s 2>&1 | %FileCheck %s --match-full-lines --strict-whitespace
2-
// RUN: not %target-swift-frontend -no-color-diagnostics -print-educational-notes -diagnostic-documentation-path %S/test-docs/ -typecheck %s 2>&1 | %FileCheck %s --match-full-lines --strict-whitespace --check-prefix=NO-COLOR
1+
// RUN: not %target-swift-frontend -color-diagnostics -diagnostic-style=llvm -print-educational-notes -diagnostic-documentation-path %S/test-docs/ -diagnostic-style llvm -typecheck %s 2>&1 | %FileCheck %s --match-full-lines --strict-whitespace
2+
// RUN: not %target-swift-frontend -no-color-diagnostics -print-educational-notes -diagnostic-documentation-path %S/test-docs/ -diagnostic-style llvm -typecheck %s 2>&1 | %FileCheck %s --match-full-lines --strict-whitespace --check-prefix=NO-COLOR
33

44
// A diagnostic with no educational notes
55
let x = 1 +

test/expr/primary/selector/fixits.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
// RUN: cp %s %t.sources/fixits.swift
2222
// RUN: %target-swift-frontend(mock-sdk: %clang-importer-sdk-nosource -I %t.overlays) -typecheck %t.sources/fixits.swift -fixit-all -emit-fixits-path %t.remapping/fixits.remap
2323
// RUN: %{python} %utils/apply-fixit-edits.py %t.remapping
24-
// RUN: %target-swift-frontend(mock-sdk: %clang-importer-sdk-nosource -I %t.overlays) -typecheck %t.sources/fixits.swift 2> %t.result
24+
// RUN: %target-swift-frontend(mock-sdk: %clang-importer-sdk-nosource -I %t.overlays) -typecheck %t.sources/fixits.swift -diagnostic-style llvm 2> %t.result
2525

2626
// RUN: %FileCheck %s < %t.result
2727
// RUN: grep -c "warning:" %t.result | grep 3

0 commit comments

Comments
 (0)