KulexiuForTeacherUITestsLaunchTests.m 904 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. //
  2. // KulexiuForTeacherUITestsLaunchTests.m
  3. // KulexiuForTeacherUITests
  4. //
  5. // Created by Kyle on 2022/3/16.
  6. //
  7. #import <XCTest/XCTest.h>
  8. @interface KulexiuForTeacherUITestsLaunchTests : XCTestCase
  9. @end
  10. @implementation KulexiuForTeacherUITestsLaunchTests
  11. + (BOOL)runsForEachTargetApplicationUIConfiguration {
  12. return YES;
  13. }
  14. - (void)setUp {
  15. self.continueAfterFailure = NO;
  16. }
  17. - (void)testLaunch {
  18. XCUIApplication *app = [[XCUIApplication alloc] init];
  19. [app launch];
  20. // Insert steps here to perform after app launch but before taking a screenshot,
  21. // such as logging into a test account or navigating somewhere in the app
  22. XCTAttachment *attachment = [XCTAttachment attachmentWithScreenshot:XCUIScreen.mainScreen.screenshot];
  23. attachment.name = @"Launch Screen";
  24. attachment.lifetime = XCTAttachmentLifetimeKeepAlways;
  25. [self addAttachment:attachment];
  26. }
  27. @end