Skip to content

Commit be6cc0e

Browse files
committed
Updates
1 parent 3e4cda8 commit be6cc0e

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

Samples/iOS-SwiftUI/iOS-SwiftUI-UITests/LaunchUITests.swift

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import Sentry
12
import SentrySampleShared
23
import SentrySampleUITestShared
34
import XCTest
@@ -49,11 +50,13 @@ class LaunchUITests: XCTestCase {
4950
XCTAssertEqual(app.staticTexts["TTDInfo"].label, "TTID and TTFD found")
5051
}
5152

52-
func testSendsError() {
53+
func testCaptureErrorReturnsValidId() {
5354
let app = newAppSession()
5455
app.safelyLaunch()
5556
app.buttons["Capture Error"].tap()
56-
XCTAssertFalse(app.staticTexts["errorId"].label.isEmpty)
57+
let errorId = app.staticTexts["errorId"].label
58+
let sentryErrorId = SentryId(uuidString: errorId)
59+
XCTAssertNotEqual(sentryErrorId.sentryIdString, SentryId.empty.sentryIdString, "The id should not be empty, since empty is used to indicate the capture did not work.")
5760
}
5861

5962
func newAppSession() -> XCUIApplication {

0 commit comments

Comments
 (0)