mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:06:00 +00:00
@@ -0,0 +1,29 @@
|
||||
//
|
||||
// ApplicationTests.swift
|
||||
// IntegrationTests
|
||||
//
|
||||
// Created by Stefan Ceriu on 27/07/2022.
|
||||
// Copyright © 2022 Element. All rights reserved.
|
||||
//
|
||||
|
||||
import XCTest
|
||||
|
||||
class ApplicationTests: XCTestCase {
|
||||
func testLaunchPerformance() throws {
|
||||
let parser = TestMeasurementParser()
|
||||
|
||||
parser.capture(testCase: self) {
|
||||
self.measure(metrics: [XCTApplicationLaunchMetric()]) {
|
||||
Application.launch()
|
||||
}
|
||||
}
|
||||
|
||||
guard let actualDuration = parser.valueForMetric(.appLaunch) else {
|
||||
XCTFail("Couldn't retrieve app launch duration")
|
||||
return
|
||||
}
|
||||
|
||||
let expectedDuration = 2.75
|
||||
XCTAssertLessThanOrEqual(actualDuration, expectedDuration)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user