Skip to content

Commit b181e72

Browse files
author
Mike Ferris
committed
Merge pull request #31 from modocache/use-percent-t
[Tests] Use %t for test output
2 parents b64c1a4 + 8181c16 commit b181e72

File tree

3 files changed

+3
-7
lines changed

3 files changed

+3
-7
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
.DS_Store
22
xcuserdata
33
.build/
4+
Output/

Tests/Functional/SingleFailingTestCase/main.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// RUN: %{swiftc} %s -o %{built_tests_dir}/SingleFailingTestCase
2-
// RUN: %{built_tests_dir}/SingleFailingTestCase > %{test_output} || true
3-
// RUN: %{xctest_checker} %{test_output} %s
2+
// RUN: %{built_tests_dir}/SingleFailingTestCase > %t || true
3+
// RUN: %{xctest_checker} %t %s
44
// CHECK: Test Case 'SingleFailingTestCase.test_fails' started.
55
// CHECK: .*/Tests/Functional/SingleFailingTestCase/main.swift:24: error: SingleFailingTestCase.test_fails : XCTAssertTrue failed -
66
// CHECK: Test Case 'SingleFailingTestCase.test_fails' failed \(\d+\.\d+ seconds\).

Tests/Functional/lit.cfg

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,6 @@ config.substitutions.append(('%{swiftc}', ' '.join(swift_exec)))
5858
built_tests_dir = tempfile.mkdtemp()
5959
config.substitutions.append(('%{built_tests_dir}', built_tests_dir))
6060

61-
# Add the %test_output substitution, which is a temporary file
62-
# used to store test output.
63-
test_output = tempfile.mkstemp()[1]
64-
config.substitutions.append(('%{test_output}', test_output))
65-
6661
# Add the %xctest_checker substitution, which is a Python script
6762
# can be used to compare the actual XCTest output to the expected
6863
# output.

0 commit comments

Comments
 (0)