Files
InvestmentTrackerApp/PortfolioJournalUITests/PortfolioJournalUITestsLaunchTests.swift
T
2026-02-01 11:12:57 +01:00

33 lines
880 B
Swift

import XCTest
/// Launch performance tests for Portfolio Journal
final class PortfolioJournalUITestsLaunchTests: XCTestCase {
override class var runsForEachTargetApplicationUIConfiguration: Bool {
true
}
override func setUpWithError() throws {
continueAfterFailure = false
}
func testLaunch() throws {
let app = XCUIApplication()
app.launch()
// Take a screenshot after launch
let attachment = XCTAttachment(screenshot: app.screenshot())
attachment.name = "Launch Screen"
attachment.lifetime = .keepAlways
add(attachment)
}
func testLaunchPerformance() throws {
if #available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 7.0, *) {
measure(metrics: [XCTApplicationLaunchMetric()]) {
XCUIApplication().launch()
}
}
}
}