diff --git a/.github/workflows/compatibility_tests.yml b/.github/workflows/compatibility_tests.yml index 5045db9..c18b365 100644 --- a/.github/workflows/compatibility_tests.yml +++ b/.github/workflows/compatibility_tests.yml @@ -32,12 +32,14 @@ jobs: - name: Run compatibility tests on OpenSwiftUI + macOS run: | swift test \ + --filter OpenSwiftUICompatibilityTests \ --build-path .build-compatibility-test-debug env: OPENSWIFTUI_COMPATIBILITY_TEST: 0 - name: Run compatibility tests on SwiftUI + macOS run: | swift test \ + --filter OpenSwiftUICompatibilityTests \ --build-path .build-compatibility-test-debug env: OPENSWIFTUI_COMPATIBILITY_TEST: 1 @@ -69,6 +71,7 @@ jobs: run: swift --version - name: Run compatibility tests on OpenSwiftUI + iOS run: | + # FIXME: xcodebuild will run all test targets. xcodebuild test \ -scheme OpenSwiftUI \ -configuration Debug \ diff --git a/Sources/OpenSwiftUICore/Log/Signpost.swift b/Sources/OpenSwiftUICore/Log/Signpost.swift index 213bf93..d9b749e 100644 --- a/Sources/OpenSwiftUICore/Log/Signpost.swift +++ b/Sources/OpenSwiftUICore/Log/Signpost.swift @@ -123,6 +123,7 @@ package struct Signpost { guard isEnabled else { return closure() } + #if canImport(Darwin) let id = OSSignpostID.makeExclusiveID(object) switch style { case let .kdebug(code): @@ -138,6 +139,9 @@ package struct Signpost { defer { os_signpost(.end, log: _signpostLog, name: name, signpostID: id) } return closure() } + #else + return closure() + #endif } @_transparent @@ -150,6 +154,7 @@ package struct Signpost { guard isEnabled else { return closure() } + #if canImport(Darwin) let id = OSSignpostID.makeExclusiveID(object) switch style { case let .kdebug(code): @@ -161,6 +166,9 @@ package struct Signpost { defer { os_signpost(.end, log: _signpostLog, name: name, signpostID: id) } return closure() } + #else + return closure() + #endif } @_transparent