Skip to content

Commit

Permalink
Update SentryHubTests.swift
Browse files Browse the repository at this point in the history
  • Loading branch information
brustolin committed Jun 14, 2023
1 parent aab4503 commit 99177cf
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions Tests/SentryTests/SentryHubTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -720,17 +720,12 @@ class SentryHubTests: XCTestCase {

fixture.currentDateProvider.setDate(date: Date(timeIntervalSince1970: 2))

let beginSession = sut.session

let event = TestData.event
event.level = .error
event.exceptions = [TestData.exception]
event.exceptions?.first?.mechanism?.handled = false
sut.capture(SentryEnvelope(event: event))

let endSession = sut.session
XCTAssertNotEqual(beginSession, endSession)


//Check whether session was finished as crashed
let envelope = fixture.client.captureEnvelopeInvocations.first
let sessionEnvelopeItem = envelope?.items.first(where: { $0.header.type == "session" })
Expand Down

0 comments on commit 99177cf

Please sign in to comment.