main

mattermost/focalboard

Last updated at: 29/12/2023 09:39

FocalboardUITests.swift

TLDR

This file contains the UI tests for the Focalboard application.

Methods

No methods are defined in this file.

Classes

FocalboardUITests

This class contains the UI tests for the Focalboard application. The setUpWithError method is called before each test method and is used to set up the initial state for the tests. The tearDownWithError method is called after each test method and is used to clean up any resources or state used by the tests. The testExample method is a sample UI test that launches the Focalboard application and can be used as a starting point for writing additional tests. The testLaunchPerformance method measures the time it takes to launch the application.

// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.

import XCTest

class FocalboardUITests: XCTestCase {

    override func setUpWithError() throws {
        // Put setup code here. This method is called before the invocation of each test method in the class.

        // In UI tests it is usually best to stop immediately when a failure occurs.
        continueAfterFailure = false

        // 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.
    }

    override func tearDownWithError() throws {
        // Put teardown code here. This method is called after the invocation of each test method in the class.
    }

    func testExample() throws {
        // UI tests must launch the application that they test.
        let app = XCUIApplication()
        app.launch()

        // Use recording to get started writing UI tests.
        // Use XCTAssert and related functions to verify your tests produce the correct results.
    }

    func testLaunchPerformance() throws {
        if #available(macOS 10.15, iOS 13.0, tvOS 13.0, *) {
            // This measures how long it takes to launch your application.
            measure(metrics: [XCTApplicationLaunchMetric()]) {
                XCUIApplication().launch()
            }
        }
    }
}