Skip to content

Commit ec5b819

Browse files
author
Ignacio Bonafonte
committed
Bump version to 0.8.0
Remove workspace path correctly from test file path
1 parent 1799b42 commit ec5b819

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

DatadogSDKTesting.xcodeproj/project.pbxproj

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2162,7 +2162,7 @@
21622162
"@executable_path/Frameworks",
21632163
"@loader_path/Frameworks",
21642164
);
2165-
MARKETING_VERSION = 0.7.0;
2165+
MARKETING_VERSION = 0.8.0;
21662166
OTHER_LDFLAGS = "-weak-lXCTestSwiftSupport";
21672167
PRODUCT_BUNDLE_IDENTIFIER = com.datadoghq.DatadogSDKTesting;
21682168
PRODUCT_NAME = DatadogSDKTesting;
@@ -2190,7 +2190,7 @@
21902190
"@executable_path/Frameworks",
21912191
"@loader_path/Frameworks",
21922192
);
2193-
MARKETING_VERSION = 0.7.0;
2193+
MARKETING_VERSION = 0.8.0;
21942194
OTHER_LDFLAGS = "-weak-lXCTestSwiftSupport";
21952195
PRODUCT_BUNDLE_IDENTIFIER = com.datadoghq.DatadogSDKTesting;
21962196
PRODUCT_NAME = DatadogSDKTesting;
@@ -2217,7 +2217,7 @@
22172217
"@executable_path/Frameworks",
22182218
"@loader_path/Frameworks",
22192219
);
2220-
MARKETING_VERSION = 0.7.0;
2220+
MARKETING_VERSION = 0.8.0;
22212221
OTHER_LDFLAGS = "-weak-lXCTestSwiftSupport";
22222222
PRODUCT_BUNDLE_IDENTIFIER = com.datadoghq.DatadogSDKTesting;
22232223
PRODUCT_NAME = DatadogSDKTesting;
@@ -2246,7 +2246,7 @@
22462246
"@executable_path/Frameworks",
22472247
"@loader_path/Frameworks",
22482248
);
2249-
MARKETING_VERSION = 0.7.0;
2249+
MARKETING_VERSION = 0.8.0;
22502250
OTHER_LDFLAGS = "-weak-lXCTestSwiftSupport";
22512251
PRODUCT_BUNDLE_IDENTIFIER = com.datadoghq.DatadogSDKTesting;
22522252
PRODUCT_NAME = DatadogSDKTesting;
@@ -2490,7 +2490,7 @@
24902490
"@executable_path/Frameworks",
24912491
"@loader_path/Frameworks",
24922492
);
2493-
MARKETING_VERSION = 0.7.0;
2493+
MARKETING_VERSION = 0.8.0;
24942494
OTHER_LDFLAGS = " -weak-lXCTestSwiftSupport";
24952495
PRODUCT_BUNDLE_IDENTIFIER = com.datadoghq.DatadogSDKTesting;
24962496
PRODUCT_NAME = DatadogSDKTesting;
@@ -2518,7 +2518,7 @@
25182518
"@executable_path/Frameworks",
25192519
"@loader_path/Frameworks",
25202520
);
2521-
MARKETING_VERSION = 0.7.0;
2521+
MARKETING_VERSION = 0.8.0;
25222522
OTHER_LDFLAGS = " -weak-lXCTestSwiftSupport";
25232523
PRODUCT_BUNDLE_IDENTIFIER = com.datadoghq.DatadogSDKTesting;
25242524
PRODUCT_NAME = DatadogSDKTesting;

Sources/DatadogSDKTesting/DDTestObserver.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -103,10 +103,10 @@ internal class DDTestObserver: NSObject, XCTestObservation {
103103
let functionName = testSuite + "." + testName
104104
if let functionInfo = currentBundleFunctionInfo[functionName] {
105105
var filePath = functionInfo.file
106-
if let srcRoot = tracer.env.sourceRoot,
107-
let rootRange = filePath.range(of: srcRoot + "/")
106+
if let workspacePath = tracer.env.workspacePath,
107+
let workspaceRange = filePath.range(of: workspacePath + "/")
108108
{
109-
filePath.removeSubrange(rootRange)
109+
filePath.removeSubrange(workspaceRange)
110110
}
111111
testSpan.setAttribute(key: DDTestTags.testSourceFile, value: filePath)
112112
testSpan.setAttribute(key: DDTestTags.testSourceStartLine, value: functionInfo.startLine)

0 commit comments

Comments
 (0)