Files
swift-mirror/test/SourceKit/Sema/sema_diag_after_edit.swift
Argyrios Kyrtzidis 8ff6a98a99 [sourcekit] Merge SourceKit into the Swift repo.
The code goes into its own sub-tree under 'tools' but tests go under 'test',
so that running 'check-swift' will also run all the SourceKit tests.

SourceKit is disabled on non-darwin platforms.
2015-11-05 01:09:08 -08:00

12 lines
535 B
Swift

let s : String = "f
// RUN: %sourcekitd-test -req=open %s -- %s == \
// RUN: -req=print-diags %s | FileCheck -check-prefix=CHECK-DIAG %s
// CHECK-DIAG: key.severity: source.diagnostic.severity.error
// Make sure that the diagnostic does not 'linger' after the edit is made.
// RUN: %sourcekitd-test -req=open %s -- %s == -req=edit -pos=1:20 -replace="\"" -length=0 %s == \
// RUN: -req=print-diags %s > %t
// RUN: FileCheck -check-prefix=CHECK-NODIAG %s < %t
// CHECK-NODIAG-NOT: key.severity: source.diagnostic.severity.error