Files
swift-mirror/test/SourceKit/Refactoring/semantic-refactoring/extract-repeated-expression.swift
Saleem Abdulrasool b67d5f0cf7 test: convert rm -rf && mkdir -p into %empty-directory
This converts the instances of the pattern for which we have a proper
substitution in lit.  This will make it easier to replace it
appropriately with Windows equivalents.
2018-03-06 14:30:54 -08:00

12 lines
401 B
Swift

func foo() -> Int {
var a = 3
a = a + 1
return 1
}
// RUN: %empty-directory(%t.result)
// RUN: %sourcekitd-test -req=extract-repeated -pos=3:11 -end-pos 3:12 -name new_name %s -- %s > %t.result/extract-repeated-expression.swift.expected
// RUN: diff -u %S/extract-repeated-expression.swift.expected %t.result/extract-repeated-expression.swift.expected
// REQUIRES-ANY: OS=macosx, OS=linux-gnu