Skip to content

Commit

Permalink
Skip more tests
Browse files Browse the repository at this point in the history
  • Loading branch information
marcosgriselli committed Oct 24, 2024
1 parent 6df7ab6 commit 66d83a4
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 16 deletions.
8 changes: 8 additions & 0 deletions Sources/TestSupport/TestHelpers.swift
Original file line number Diff line number Diff line change
Expand Up @@ -124,3 +124,11 @@ extension XCTestCase {
describe(name, test)
}
}


public func skipIfNecessary() throws {
#if os(Linux) && swift(<6.0.2)
// https://github.com/swiftlang/swift-foundation/pull/1002
throw XCTSkip("Skipping test on Linux until PropertyListDecoder issues are fixed.")
#endif
}
13 changes: 3 additions & 10 deletions Tests/PerformanceTests/PerformanceTests.swift
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import Foundation
import PathKit
import ProjectSpec
import TestSupport
import XcodeGenKit
import XcodeProj
import XCTest
Expand Down Expand Up @@ -62,11 +63,7 @@ class FixturePerformanceTests: XCTestCase {
}

func testFixtureGeneration() throws {
#if os(Linux) && swift(<6.0.2)
// https://github.com/swiftlang/swift-foundation/pull/1002
throw XCTSkip("Skipping test on Linux until PropertyListDecoder issues are fixed.")
#endif

try skipIfNecessary()
let project = try Project(path: specPath)
measure {
let generator = ProjectGenerator(project: project)
Expand All @@ -75,11 +72,7 @@ class FixturePerformanceTests: XCTestCase {
}

func testFixtureWriting() throws {
#if os(Linux) && swift(<6.0.2)
// https://github.com/swiftlang/swift-foundation/pull/1002
throw XCTSkip("Skipping test on Linux until PropertyListDecoder issues are fixed.")
#endif

try skipIfNecessary()
let project = try Project(path: specPath)
let generator = ProjectGenerator(project: project)
let xcodeProject = try generator.generateXcodeProject(userName: "someUser")
Expand Down
3 changes: 2 additions & 1 deletion Tests/XcodeGenKitTests/ProjectGeneratorTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,8 @@ class ProjectGeneratorTests: XCTestCase {
}
}

func testTargets() {
func testTargets() throws {
try skipIfNecessary()
describe {

let project = Project(name: "test", targets: targets)
Expand Down
3 changes: 2 additions & 1 deletion Tests/XcodeGenKitTests/SchemeGeneratorTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,8 @@ private let uiTest = Target(

class SchemeGeneratorTests: XCTestCase {

func testSchemes() {
func testSchemes() throws {
try skipIfNecessary()
describe {

let buildTarget = Scheme.BuildTarget(target: .local(app.name))
Expand Down
5 changes: 1 addition & 4 deletions Tests/XcodeGenKitTests/SourceGeneratorTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,7 @@ import TestSupport
class SourceGeneratorTests: XCTestCase {

func testSourceGenerator() throws {
#if os(Linux) && swift(<6.0.2)
// https://github.com/swiftlang/swift-foundation/pull/1002
throw XCTSkip("Skipping test on Linux until PropertyListDecoder issues are fixed.")
#endif
try skipIfNecessary()
describe {

let directoryPath = Path("TestDirectory")
Expand Down

0 comments on commit 66d83a4

Please sign in to comment.