Source code for the WriteFreely SwiftUI app for iOS, iPadOS, and macOS
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

37 lines
1.3 KiB

  1. import XCTest
  2. class Tests_iOS: XCTestCase {
  3. override func setUpWithError() throws {
  4. // Put setup code here. This method is called before the invocation of each test method in the class.
  5. // In UI tests it is usually best to stop immediately when a failure occurs.
  6. continueAfterFailure = false
  7. // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests
  8. // before they run. The setUp method is a good place to do this.
  9. }
  10. override func tearDownWithError() throws {
  11. // Put teardown code here. This method is called after the invocation of each test method in the class.
  12. }
  13. func testExample() throws {
  14. // UI tests must launch the application that they test.
  15. let app = XCUIApplication()
  16. app.launch()
  17. // Use recording to get started writing UI tests.
  18. // Use XCTAssert and related functions to verify your tests produce the correct results.
  19. }
  20. func testLaunchPerformance() throws {
  21. if #available(macOS 10.15, iOS 13.0, tvOS 13.0, *) {
  22. // This measures how long it takes to launch your application.
  23. measure(metrics: [XCTApplicationLaunchMetric()]) {
  24. XCUIApplication().launch()
  25. }
  26. }
  27. }
  28. }