Skip to content

Commit 2c6c863

Browse files
authored
Merge branch 'main' into evaluateCondition
2 parents e420c87 + eef2340 commit 2c6c863

File tree

181 files changed

+6220
-5035
lines changed

Some content is hidden

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

181 files changed

+6220
-5035
lines changed
Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
# This source file is part of the Swift.org open source project
2+
#
3+
# Copyright (c) 2025 Apple Inc. and the Swift project authors
4+
# Licensed under Apache License v2.0 with Runtime Library Exception
5+
#
6+
# See https://swift.org/LICENSE.txt for license information
7+
# See https://swift.org/CONTRIBUTORS.txt for Swift project authors
8+
9+
name: 🪲 Report a bug
10+
description: >
11+
Report a deviation from expected or documented behavior.
12+
labels: [bug, triage-needed]
13+
body:
14+
- type: markdown
15+
attributes:
16+
value: >
17+
This repository hosts the Swift Testing library and its documentation.
18+
It does _not_ track feedback for Xcode and other closed source Apple
19+
developer software such as XCTest; please direct that to
20+
[Feedback Assistant](https://developer.apple.com/bug-reporting) instead.
21+
- type: textarea
22+
attributes:
23+
label: Description
24+
description: >
25+
A concise description of what causes the problem, in human language.
26+
Though not required, it may help us to more accurately triage the issue
27+
as well as understand a non-trivial test case.
28+
validations:
29+
required: false
30+
- type: textarea
31+
attributes:
32+
label: Reproduction
33+
description: >
34+
Provide an example, preferably in a Markdown code block, and explain how
35+
to build or run it to reproduce the problem. If the problem is a poor or
36+
unexpected diagnostic, fix-it, or other output, please show this output
37+
as is. For example, paste it from the terminal. Consider reducing the
38+
example to the smallest amount of code possible — a smaller example is
39+
easier to reason about and more appealing to contributors.
40+
value: |
41+
```swift
42+
43+
```
44+
validations:
45+
required: true
46+
- type: textarea
47+
attributes:
48+
label: Expected behavior
49+
description: Describe the behavior you expected.
50+
validations:
51+
required: true
52+
- type: textarea
53+
attributes:
54+
label: Environment
55+
description: >
56+
Provide details about the environment in which this problem occurs.
57+
Include the versions of Swift Testing and the Swift toolchain. If you
58+
suspect the problem might be specific to a particular platform, please
59+
specify the platform and OS version as well.
60+
placeholder: |
61+
Swift Testing version: (shown in `swift test` output)
62+
$ swift --version
63+
$ uname -a
64+
validations:
65+
required: true
66+
- type: textarea
67+
attributes:
68+
label: Additional information
69+
description: >
70+
Any complementary information that could help others to work around the
71+
problem, and us to better understand the problem and its impact. For
72+
example, a link to a discussion or post that motivated this report.
73+
validations:
74+
required: false
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
# This source file is part of the Swift.org open source project
2+
#
3+
# Copyright (c) 2025 Apple Inc. and the Swift project authors
4+
# Licensed under Apache License v2.0 with Runtime Library Exception
5+
#
6+
# See https://swift.org/LICENSE.txt for license information
7+
# See https://swift.org/CONTRIBUTORS.txt for Swift project authors
8+
9+
name: 🌟 Request a change
10+
description: >
11+
Request a feature, API, improvement, or other change.
12+
labels: [enhancement, triage-needed]
13+
body:
14+
- type: markdown
15+
attributes:
16+
value: >
17+
This repository hosts the Swift Testing library and its documentation.
18+
It does _not_ track feedback for Xcode and other closed source Apple
19+
developer software such as XCTest; please direct that to
20+
[Feedback Assistant](https://developer.apple.com/bug-reporting) instead.
21+
22+
___
23+
24+
Swift Testing is guided by a community-driven evolution process.
25+
Submitting this form is not a guarantee that the request will be
26+
considered or implemented. If the request implies an addition, removal,
27+
or change to the features of Swift Testing or its public interfaces,
28+
please consider socializing it on the
29+
[Swift forums](https://forums.swift.org/c/related-projects/swift-testing)
30+
instead. The Swift forums are the preferred space for sharing ideas and
31+
discussing them with the Swift community.
32+
- type: textarea
33+
attributes:
34+
label: Motivation
35+
description: >
36+
Describe the problems that this idea seeks to address. If the problem is
37+
that some common pattern is currently hard to express, show how one can
38+
currently get a similar effect and describe its drawbacks. If it's
39+
completely new functionality that cannot be emulated, motivate why this
40+
new functionality would help create better Swift tests.
41+
validations:
42+
required: true
43+
- type: textarea
44+
attributes:
45+
label: Proposed solution
46+
description: >
47+
Describe the proposed solution to the problem. Provide examples and
48+
describe how they work. Show how this solution is better than current
49+
workarounds: is it cleaner, safer, or more efficient?
50+
validations:
51+
required: true
52+
- type: textarea
53+
attributes:
54+
label: Alternatives considered
55+
description: >
56+
Any alternative approaches that were considered, and why the _proposed
57+
solution_ was chosen instead.
58+
validations:
59+
required: false
60+
- type: textarea
61+
attributes:
62+
label: Additional information
63+
description: >
64+
Any complementary information that could be valuable to an author of a
65+
formal proposal, an implementor, or future discussions. For example, a
66+
link to a discussion or post that motivated this request.
67+
validations:
68+
required: false

.github/ISSUE_TEMPLATE/03-task.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# This source file is part of the Swift.org open source project
2+
#
3+
# Copyright (c) 2025 Apple Inc. and the Swift project authors
4+
# Licensed under Apache License v2.0 with Runtime Library Exception
5+
#
6+
# See https://swift.org/LICENSE.txt for license information
7+
# See https://swift.org/CONTRIBUTORS.txt for Swift project authors
8+
9+
name: ⚙️ Track a task
10+
description: >
11+
Tasks can be used to track internal work, extract individual subtasks from a
12+
larger issue, or can serve as umbrella issues themselves.
13+
labels: []
14+
body:
15+
- type: markdown
16+
attributes:
17+
value: >
18+
This repository hosts the Swift Testing library and its documentation.
19+
It does _not_ track feedback for Xcode and other closed source Apple
20+
developer software such as XCTest; please direct that to
21+
[Feedback Assistant](https://developer.apple.com/bug-reporting) instead.
22+
- type: textarea
23+
attributes:
24+
label: Description
25+
description: >
26+
A comprehensive description of the task, in human language.
27+
validations:
28+
required: true
29+
- type: textarea
30+
attributes:
31+
label: Additional information
32+
description: >
33+
Any complementary information that could be valuable to an implementor.
34+
For example, a link to a discussion or post that motivated this task.
35+
validations:
36+
required: false

.github/ISSUE_TEMPLATE/BUG_REPORT.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

.github/ISSUE_TEMPLATE/FEATURE_REQUEST.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# This source file is part of the Swift.org open source project
2+
#
3+
# Copyright (c) 2025 Apple Inc. and the Swift project authors
4+
# Licensed under Apache License v2.0 with Runtime Library Exception
5+
#
6+
# See https://swift.org/LICENSE.txt for license information
7+
# See https://swift.org/CONTRIBUTORS.txt for Swift project authors
8+
9+
blank_issues_enabled: true
10+
contact_links:
11+
- name: 🌐 Discuss an idea
12+
url: https://forums.swift.org/c/related-projects/swift-testing
13+
about: >
14+
Share an idea with the Swift Testing community.
15+
- name: 📄 Formally propose a change
16+
url: https://github.com/swiftlang/swift-testing/blob/main/Documentation/Proposals/0000-proposal-template.md
17+
about: >
18+
Formally propose an addition, removal, or change to the APIs or features
19+
of Swift Testing.
20+
- name: 🙋 Ask a question
21+
url: https://forums.swift.org/c/related-projects/swift-testing
22+
about: >
23+
Ask a question about or get help with Swift Testing. Beginner questions
24+
welcome!
25+
- name: 🪲 Report an issue with Swift Package Manager
26+
url: https://github.com/swiftlang/swift-package-manager/issues/new/choose
27+
about: >
28+
Report an issue with Swift Package Manager, which includes the
29+
"swift test" CLI tool.
30+
- name: 🪲 Report an issue with Apple software using Feedback Assistant
31+
url: https://developer.apple.com/bug-reporting
32+
about: >
33+
Report an issue with Xcode or other closed source Apple developer
34+
software such as XCTest.
35+
- name: 🪲 Report an issue with the VS Code Swift plugin
36+
url: https://github.com/swiftlang/vscode-swift/issues/new/choose
37+
about: >
38+
Report an issue with the Swift plugin for VS Code, which integrates with
39+
Swift Testing.
40+
- name: 📖 Learn about Swift Testing
41+
url: https://swiftpackageindex.com/swiftlang/swift-testing/main/documentation/testing
42+
about: >
43+
Read the official Swift Testing documentation.

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,6 @@ _[Explain here the context, and why you're making that change. What is the probl
88

99
_[Describe the modifications you've done.]_
1010

11-
### Result:
12-
13-
_[After your change, what will change.]_
14-
1511
### Checklist:
1612

1713
- [ ] Code and documentation should follow the style of the [Style Guide](https://github.com/apple/swift-testing/blob/main/Documentation/StyleGuide.md).

.spi.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,5 @@ metadata:
33
authors: Apple Inc.
44
builder:
55
configs:
6-
- swift_version: 6.0
7-
documentation_targets: [Testing]
6+
- documentation_targets: [Testing]
87
scheme: Testing

CMakeLists.txt

Lines changed: 19 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,14 @@
99
cmake_minimum_required(VERSION 3.19.6...3.29)
1010

1111
if(POLICY CMP0157)
12-
cmake_policy(SET CMP0157 NEW)
12+
if(CMAKE_HOST_SYSTEM_NAME STREQUAL Windows AND CMAKE_SYSTEM_NAME STREQUAL Android)
13+
# CMP0157 causes builds to fail when targetting Android with the Windows
14+
# toolchain, because the early swift-driver isn't (yet) available. Disable
15+
# it for now.
16+
cmake_policy(SET CMP0157 OLD)
17+
else()
18+
cmake_policy(SET CMP0157 NEW)
19+
endif()
1320
endif()
1421

1522
project(SwiftTesting
@@ -32,18 +39,21 @@ set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
3239
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
3340
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
3441

42+
set(CMAKE_INSTALL_RPATH "$<IF:$<PLATFORM_ID:Darwin>,@loader_path/..,$ORIGIN>")
43+
set(CMAKE_INSTALL_REMOVE_ENVIRONMENT_RPATH YES)
44+
3545
set(CMAKE_MSVC_RUNTIME_LIBRARY MultiThreadedDLL)
3646
set(CMAKE_CXX_STANDARD 20)
3747
set(CMAKE_Swift_LANGUAGE_VERSION 6)
3848
set(CMAKE_Swift_MODULE_DIRECTORY ${CMAKE_BINARY_DIR}/swift)
3949

40-
if(NOT SWIFT_SYSTEM_NAME)
41-
if(CMAKE_SYSTEM_NAME STREQUAL Darwin)
42-
set(SWIFT_SYSTEM_NAME macosx)
43-
else()
44-
set(SWIFT_SYSTEM_NAME "$<LOWER_CASE:${CMAKE_SYSTEM_NAME}>")
45-
endif()
46-
endif()
47-
50+
include(PlatformInfo)
4851
include(SwiftModuleInstallation)
52+
53+
option(SwiftTesting_INSTALL_NESTED_SUBDIR "Install libraries under a platform and architecture subdirectory" NO)
54+
set(SwiftTesting_INSTALL_LIBDIR "${CMAKE_INSTALL_LIBDIR}/swift$<$<NOT:$<BOOL:${BUILD_SHARED_LIBS}>>:_static>/${SwiftTesting_PLATFORM_SUBDIR}$<$<AND:$<PLATFORM_ID:Darwin>,$<NOT:$<BOOL:${SwiftTesting_INSTALL_NESTED_SUBDIR}>>>:/testing>$<$<BOOL:${SwiftTesting_INSTALL_NESTED_SUBDIR}>:/${SwiftTesting_ARCH_SUBDIR}>")
55+
set(SwiftTesting_INSTALL_SWIFTMODULEDIR "${CMAKE_INSTALL_LIBDIR}/swift$<$<NOT:$<BOOL:${BUILD_SHARED_LIBS}>>:_static>/${SwiftTesting_PLATFORM_SUBDIR}$<$<AND:$<PLATFORM_ID:Darwin>,$<NOT:$<BOOL:${SwiftTesting_INSTALL_NESTED_SUBDIR}>>>:/testing>")
56+
57+
add_compile_options($<$<COMPILE_LANGUAGE:Swift>:-no-toolchain-stdlib-rpath>)
58+
4959
add_subdirectory(Sources)

CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@
88
# See https://swift.org/CONTRIBUTORS.txt for Swift project authors
99
#
1010

11-
* @stmontgomery @grynspan @dennisweissmann @briancroom @SeanROlszewski @suzannaratcliff
11+
* @stmontgomery @grynspan @briancroom @SeanROlszewski @suzannaratcliff

Documentation/ABI/JSON.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ See https://swift.org/CONTRIBUTORS.txt for Swift project authors
1313
This document outlines the JSON schemas used by the testing library for its ABI
1414
entry point and for the `--event-stream-output-path` command-line argument. For
1515
more information about the ABI entry point, see the documentation for
16-
[ABIv0.EntryPoint](https://github.com/search?q=repo%3Aapple%2Fswift-testing%EntryPoint&type=code).
16+
[ABI.v0.EntryPoint](https://github.com/search?q=repo%3Aswiftlang%2Fswift-testing%20EntryPoint&type=code).
1717

1818
## Modified Backus-Naur form
1919

0 commit comments

Comments
 (0)