]> git.r.bdr.sh - rbdr/captura/blame - CapturaUITests/CapturaUITests.swift
Format the code
[rbdr/captura] / CapturaUITests / CapturaUITests.swift
CommitLineData
5802c153
RBR
1/*
2 Copyright (C) 2024 Rubén Beltrán del Río
3
4 This program is free software: you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation, either version 3 of the License, or
7 (at your option) any later version.
8
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
13
14 You should have received a copy of the GNU General Public License
15 along with this program. If not, see https://captura.tranquil.systems.
16 */
bf063563
RBR
17
18import XCTest
19
20final class CapturaUITests: XCTestCase {
21
505c1e62
RBR
22 override func setUpWithError() throws {
23 // Put setup code here. This method is called before the invocation of each test method in the class.
bf063563 24
505c1e62
RBR
25 // In UI tests it is usually best to stop immediately when a failure occurs.
26 continueAfterFailure = false
bf063563 27
505c1e62
RBR
28 // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this.
29 }
bf063563 30
505c1e62
RBR
31 override func tearDownWithError() throws {
32 // Put teardown code here. This method is called after the invocation of each test method in the class.
33 }
bf063563 34
505c1e62
RBR
35 func testExample() throws {
36 // UI tests must launch the application that they test.
37 let app = XCUIApplication()
38 app.launch()
bf063563 39
505c1e62
RBR
40 // Use XCTAssert and related functions to verify your tests produce the correct results.
41 }
bf063563 42
505c1e62
RBR
43 func testLaunchPerformance() throws {
44 if #available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 7.0, *) {
45 // This measures how long it takes to launch your application.
46 measure(metrics: [XCTApplicationLaunchMetric()]) {
47 XCUIApplication().launch()
48 }
bf063563 49 }
505c1e62 50 }
bf063563 51}