Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tests: Convert Basics/FileSystem/* to Swift Testing #8448

Conversation

bkhouri
Copy link
Contributor

@bkhouri bkhouri commented Apr 3, 2025

Convert test from XCTest to Swift Testing.

  • Tests/BasicsTests/FileSystem/FileSystemTests.swift
  • Tests/BasicsTests/FileSystem/PathShimTests.swift
  • Tests/BasicsTests/FileSystem/PathTests.swift
  • Tests/BasicsTests/FileSystem/TemporaryFileTests.swift
  • Tests/BasicsTests/FileSystem/VFSTests.swift

relates to: #8433
depends on #8467

@bkhouri
Copy link
Contributor Author

bkhouri commented Apr 3, 2025

@swift-ci please test

@bkhouri
Copy link
Contributor Author

bkhouri commented Apr 3, 2025

@swift-ci test self hosted windows

@bkhouri bkhouri added the test suite improvements to SwiftPM test suite label Apr 3, 2025
@bkhouri bkhouri requested review from stmontgomery and grynspan April 3, 2025 20:02
@bkhouri bkhouri marked this pull request as ready for review April 3, 2025 20:02
@bkhouri
Copy link
Contributor Author

bkhouri commented Apr 3, 2025

Recreating part of #8093

@bkhouri bkhouri force-pushed the t/main/convert_pathtests_to_swift_testing branch from f77a6f1 to 304833a Compare April 3, 2025 20:20
@bkhouri
Copy link
Contributor Author

bkhouri commented Apr 3, 2025

@swift-ci test

@bkhouri
Copy link
Contributor Author

bkhouri commented Apr 3, 2025

@swift-ci test self hosted windows

@bkhouri
Copy link
Contributor Author

bkhouri commented Apr 3, 2025

@swift-ci test windows

bkhouri added a commit to bkhouri/swift-package-manager that referenced this pull request Apr 4, 2025
Update the Basics/FileSystem/*.swift test to enable more tests that pass on Windows

- Update function name to get a sense of which tests are passing on Windows

Fixes: swiftlang#8433
Issue: rdar://148248105
Depends on: swiftlang#8448
@bkhouri bkhouri force-pushed the t/main/convert_pathtests_to_swift_testing branch from 304833a to c7673b6 Compare April 4, 2025 02:00
@bkhouri
Copy link
Contributor Author

bkhouri commented Apr 4, 2025

@swift-ci please test

@bkhouri
Copy link
Contributor Author

bkhouri commented Apr 4, 2025

@swift-ci test self hosted windows

bkhouri added a commit to bkhouri/swift-package-manager that referenced this pull request Apr 4, 2025
Update the Basics/FileSystem/*.swift test to enable more tests that pass on Windows

- Update function name to get a sense of which tests are passing on Windows

Fixes: swiftlang#8433
Issue: rdar://148248105
Depends on: swiftlang#8448
bkhouri added a commit to bkhouri/swift-package-manager that referenced this pull request Apr 4, 2025
Update the Basics/FileSystem/*.swift test to enable more tests that pass on Windows

- Update function name to get a sense of which tests are passing on Windows

Depends on: swiftlang#8448
Partially Addresses: swiftlang#8433
Issue: rdar://148248105
bkhouri added a commit to bkhouri/swift-package-manager that referenced this pull request Apr 4, 2025
Enable more tests on Windows that are currently passing in
Basics/FileSystem/*.swift

Depends on: swiftlang#8448
Partially Addresses: swiftlang#8433
Issue: rdar://148248105
bkhouri added a commit to bkhouri/swift-package-manager that referenced this pull request Apr 4, 2025
Enable more tests on Windows that are currently passing in
Basics/FileSystem/*.swift

Depends on: swiftlang#8448
Partially Addresses: swiftlang#8433
Issue: rdar://148248105
import class Foundation.ProcessInfo
import Testing

extension Trait where Self == Testing.ConditionTrait {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given Testing.ConditionTrait conforms to Trait, can't we simply write this instead?

extension Testing.ConditionTrait {

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file was a direct copy from IntegartionTests/Sources/IntegrationTests. I want to avoid changing it drastically until #8223 is completed

bkhouri added 2 commits April 8, 2025 15:19
Until $8223 is fixed copy some helpers from `IntergrationTests/Source/IntegrationTests``
to `Test/_InternalTestSupport` so we can re-use the functionality.

Related to: swiftlang#8433
rdar://148248105
Convert test from XCTest to Swift Testing.
  - Tests/BasicsTests/FileSystem/FileSystemTests.swift
  - Tests/BasicsTests/FileSystem/PathShimTests.swift
  - Tests/BasicsTests/FileSystem/PathTests.swift
  - Tests/BasicsTests/FileSystem/TemporaryFileTests.swift
  - Tests/BasicsTests/FileSystem/VFSTests.swift

relates to: swiftlang#8433
@bkhouri bkhouri force-pushed the t/main/convert_pathtests_to_swift_testing branch from c7673b6 to a07e0b1 Compare April 8, 2025 19:42
bkhouri added a commit to bkhouri/swift-package-manager that referenced this pull request Apr 8, 2025
Enable more tests on Windows that are currently passing in
Basics/FileSystem/*.swift

Depends on: swiftlang#8448
Partially Addresses: swiftlang#8433
Issue: rdar://148248105
@bkhouri
Copy link
Contributor Author

bkhouri commented Apr 8, 2025

@swift-ci test

@bkhouri
Copy link
Contributor Author

bkhouri commented Apr 8, 2025

@swift-ci test self hosted windows

@bkhouri
Copy link
Contributor Author

bkhouri commented Apr 9, 2025

The changes in this PR are also included in #8450. Since there are some tests that fail in the self hosted pipeline in this PR, I am closing this and will continue the work in #8450 .

@bkhouri bkhouri closed this Apr 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
test suite improvements to SwiftPM test suite
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants