Skip to content

Commit aeb20f0

Browse files
committed
deprecate Baggage names
1 parent 57ac081 commit aeb20f0

File tree

4 files changed

+4
-40
lines changed

4 files changed

+4
-40
lines changed

Sources/InstrumentationBaggage/CompatibilityShims.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@
1515

1616
@_exported import ServiceContextModule
1717

18+
@available(*, deprecated, message: "Use 'ServiceContext' from 'ServiceContextModule' instead.")
1819
public typealias Baggage = ServiceContext
20+
@available(*, deprecated, message: "Use 'ServiceContext' from 'ServiceContextModule' instead.")
1921
public typealias BaggageKey = ServiceContextKey
22+
@available(*, deprecated, message: "Use 'ServiceContext' from 'ServiceContextModule' instead.")
2023
public typealias AnyBaggageKey = AnyServiceContextKey

Tests/ServiceContextTests/ServiceContext+XCTest.swift

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

Tests/ServiceContextTests/ServiceContextTests+XCTest.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ extension ServiceContextTests {
3232
("test_forEachIteratesOverAllServiceContextItems", test_forEachIteratesOverAllServiceContextItems),
3333
("test_TODO_doesNotCrashWithoutExplicitCompilerFlag", test_TODO_doesNotCrashWithoutExplicitCompilerFlag),
3434
("test_automaticPropagationThroughTaskLocal", test_automaticPropagationThroughTaskLocal),
35-
("test", test),
3635
]
3736
}
3837
}

Tests/ServiceContextTests/ServiceContextTests.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ final class ServiceContextTests: XCTestCase {
9090
actor SomeActor {
9191
var value: Int = 0
9292

93-
func test() async {
93+
func check() async {
9494
ServiceContext.$current.withValue(.topLevel) {
9595
value = 12 // should produce no warnings
9696
}

0 commit comments

Comments
 (0)