Skip to content

Commit a8c48d2

Browse files
authored
Merge pull request #2982 from rintaro/tests-substitution-utils
[lit] Add %utils and %line-directive substitutions. Use %gyb
2 parents 7e34031 + 1bdce7c commit a8c48d2

File tree

182 files changed

+527
-523
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

182 files changed

+527
-523
lines changed

test/1_stdlib/ArrayTraps.swift.gyb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
// RUN: rm -rf %t
22
// RUN: mkdir -p %t
3-
// RUN: %S/../../utils/gyb %s -o %t/ArrayTraps.swift
4-
// RUN: %S/../../utils/line-directive %t/ArrayTraps.swift -- %target-build-swift %t/ArrayTraps.swift -o %t/a.out_Debug
5-
// RUN: %S/../../utils/line-directive %t/ArrayTraps.swift -- %target-build-swift %t/ArrayTraps.swift -o %t/a.out_Release -O
3+
// RUN: %gyb %s -o %t/ArrayTraps.swift
4+
// RUN: %line-directive %t/ArrayTraps.swift -- %target-build-swift %t/ArrayTraps.swift -o %t/a.out_Debug
5+
// RUN: %line-directive %t/ArrayTraps.swift -- %target-build-swift %t/ArrayTraps.swift -o %t/a.out_Release -O
66
//
7-
// RUN: %S/../../utils/line-directive %t/ArrayTraps.swift -- %target-run %t/a.out_Debug
8-
// RUN: %S/../../utils/line-directive %t/ArrayTraps.swift -- %target-run %t/a.out_Release
7+
// RUN: %line-directive %t/ArrayTraps.swift -- %target-run %t/a.out_Debug
8+
// RUN: %line-directive %t/ArrayTraps.swift -- %target-run %t/a.out_Release
99
// REQUIRES: executable_test
1010

1111
import StdlibUnittest

test/1_stdlib/ArrayTrapsObjC.swift.gyb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
// RUN: rm -rf %t
22
// RUN: mkdir -p %t
3-
// RUN: %S/../../utils/gyb %s -o %t/ArrayTraps.swift
4-
// RUN: %S/../../utils/line-directive %t/ArrayTraps.swift -- %target-build-swift %t/ArrayTraps.swift -o %t/a.out_Debug
5-
// RUN: %S/../../utils/line-directive %t/ArrayTraps.swift -- %target-build-swift %t/ArrayTraps.swift -o %t/a.out_Release -O
3+
// RUN: %gyb %s -o %t/ArrayTraps.swift
4+
// RUN: %line-directive %t/ArrayTraps.swift -- %target-build-swift %t/ArrayTraps.swift -o %t/a.out_Debug
5+
// RUN: %line-directive %t/ArrayTraps.swift -- %target-build-swift %t/ArrayTraps.swift -o %t/a.out_Release -O
66
//
7-
// RUN: %S/../../utils/line-directive %t/ArrayTraps.swift -- %target-run %t/a.out_Debug
8-
// RUN: %S/../../utils/line-directive %t/ArrayTraps.swift -- %target-run %t/a.out_Release
7+
// RUN: %line-directive %t/ArrayTraps.swift -- %target-run %t/a.out_Debug
8+
// RUN: %line-directive %t/ArrayTraps.swift -- %target-run %t/a.out_Release
99
// REQUIRES: executable_test
1010
// REQUIRES: objc_interop
1111

test/1_stdlib/BridgeStorage.swift.gyb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@
1515
// distinguish these cases efficiently.
1616
//
1717
//===----------------------------------------------------------------------===//
18-
// RUN: rm -rf %t && mkdir -p %t && %S/../../utils/gyb %s -o %t/out.swift
19-
// RUN: %S/../../utils/line-directive %t/out.swift -- %target-build-swift -parse-stdlib %t/out.swift -o %t/a.out
20-
// RUN: %S/../../utils/line-directive %t/out.swift -- %target-run %t/a.out
18+
// RUN: rm -rf %t && mkdir -p %t && %gyb %s -o %t/out.swift
19+
// RUN: %line-directive %t/out.swift -- %target-build-swift -parse-stdlib %t/out.swift -o %t/a.out
20+
// RUN: %line-directive %t/out.swift -- %target-run %t/a.out
2121
// REQUIRES: executable_test
2222

2323
// REQUIRES: objc_interop

test/1_stdlib/CastTraps.swift.gyb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// -*- swift -*-
22
// RUN: rm -rf %t ; mkdir -p %t
3-
// RUN: %S/../../utils/gyb %s -o %t/CastTraps.swift
4-
// RUN: %S/../../utils/line-directive %t/CastTraps.swift -- %target-build-swift %t/CastTraps.swift -o %t/a.out
5-
// RUN: %S/../../utils/line-directive %t/CastTraps.swift -- %target-run %t/a.out
3+
// RUN: %gyb %s -o %t/CastTraps.swift
4+
// RUN: %line-directive %t/CastTraps.swift -- %target-build-swift %t/CastTraps.swift -o %t/a.out
5+
// RUN: %line-directive %t/CastTraps.swift -- %target-run %t/a.out
66
// REQUIRES: executable_test
77

88
// FIXME: Casting.cpp has dozens of places to fail a cast. This test does not

test/1_stdlib/FloatingPoint.swift.gyb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
// RUN: rm -rf %t && mkdir -p %t && %S/../../utils/gyb %s -o %t/FloatingPoint.swift
2-
// RUN: %S/../../utils/line-directive %t/FloatingPoint.swift -- %target-build-swift -parse-stdlib -Xfrontend -disable-access-control %t/FloatingPoint.swift -o %t/a.out
3-
// RUN: %S/../../utils/line-directive %t/FloatingPoint.swift -- %target-run %t/a.out
1+
// RUN: rm -rf %t && mkdir -p %t && %gyb %s -o %t/FloatingPoint.swift
2+
// RUN: %line-directive %t/FloatingPoint.swift -- %target-build-swift -parse-stdlib -Xfrontend -disable-access-control %t/FloatingPoint.swift -o %t/a.out
3+
// RUN: %line-directive %t/FloatingPoint.swift -- %target-run %t/a.out
44
// REQUIRES: executable_test
55

66
%{

test/1_stdlib/InputStream.swift.gyb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
//===----------------------------------------------------------------------===//
1212
// -*- swift -*-
1313
// RUN: rm -rf %t ; mkdir -p %t
14-
// RUN: %S/../../utils/gyb %s -o %t/InputStream.swift
15-
// RUN: %S/../../utils/line-directive %t/InputStream.swift -- %target-build-swift %t/InputStream.swift -o %t/a.out
16-
// RUN: %S/../../utils/line-directive %t/InputStream.swift -- %target-run %t/a.out
14+
// RUN: %gyb %s -o %t/InputStream.swift
15+
// RUN: %line-directive %t/InputStream.swift -- %target-build-swift %t/InputStream.swift -o %t/a.out
16+
// RUN: %line-directive %t/InputStream.swift -- %target-run %t/a.out
1717
// REQUIRES: executable_test
1818

1919
import StdlibUnittest

test/1_stdlib/NumericParsing.swift.gyb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
//===----------------------------------------------------------------------===//
1212
// -*- swift -*-
1313
// RUN: rm -rf %t ; mkdir -p %t
14-
// RUN: %S/../../utils/gyb -DCMAKE_SIZEOF_VOID_P=%target-ptrsize %s -o %t/NumericParsing.swift
15-
// RUN: %S/../../utils/line-directive %t/NumericParsing.swift -- %target-build-swift %t/NumericParsing.swift -o %t/a.out
16-
// RUN: %S/../../utils/line-directive %t/NumericParsing.swift -- %target-run %t/a.out
14+
// RUN: %gyb -DCMAKE_SIZEOF_VOID_P=%target-ptrsize %s -o %t/NumericParsing.swift
15+
// RUN: %line-directive %t/NumericParsing.swift -- %target-build-swift %t/NumericParsing.swift -o %t/a.out
16+
// RUN: %line-directive %t/NumericParsing.swift -- %target-run %t/a.out
1717
// REQUIRES: executable_test
1818
%{
1919
from SwiftIntTypes import all_integer_types

test/1_stdlib/Tuple.swift.gyb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// RUN: rm -f %t.swift %t.out
22

3-
// RUN: %S/../../utils/gyb %s -o %t.swift
4-
// RUN: %S/../../utils/line-directive %t.swift -- %target-build-swift %t.swift -o %t.out
5-
// RUN: %S/../../utils/line-directive %t.swift -- %target-run %t.out
3+
// RUN: %gyb %s -o %t.swift
4+
// RUN: %line-directive %t.swift -- %target-build-swift %t.swift -o %t.out
5+
// RUN: %line-directive %t.swift -- %target-run %t.out
66
// REQUIRES: executable_test
77

88
import StdlibUnittest

test/1_stdlib/UnsafePointer.swift.gyb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
// RUN: rm -rf %t && mkdir -p %t && %S/../../utils/gyb %s -o %t/UnsafePointer.swift
2-
// RUN: %S/../../utils/line-directive %t/UnsafePointer.swift -- %target-build-swift %t/UnsafePointer.swift -o %t/a.out
3-
// RUN: %S/../../utils/line-directive %t/UnsafePointer.swift -- %target-run %t/a.out
1+
// RUN: rm -rf %t && mkdir -p %t && %gyb %s -o %t/UnsafePointer.swift
2+
// RUN: %line-directive %t/UnsafePointer.swift -- %target-build-swift %t/UnsafePointer.swift -o %t/a.out
3+
// RUN: %line-directive %t/UnsafePointer.swift -- %target-run %t/a.out
44
// REQUIRES: executable_test
55

66
import StdlibUnittest

test/1_stdlib/simd.swift.gyb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// RUN: rm -f %t.swift %t.out
22

3-
// RUN: %S/../../utils/gyb %s -o %t.swift
4-
// RUN: %S/../../utils/line-directive %t.swift -- %target-build-swift %t.swift -o %t.out
5-
// RUN: %S/../../utils/line-directive %t.swift -- %target-run %t.out
3+
// RUN: %gyb %s -o %t.swift
4+
// RUN: %line-directive %t.swift -- %target-build-swift %t.swift -o %t.out
5+
// RUN: %line-directive %t.swift -- %target-run %t.out
66
// REQUIRES: executable_test
77

88
// FIXME: No simd module on linux rdar://problem/20795411

0 commit comments

Comments
 (0)