I have a class teardown which is trying to remove the app, but it doesn\'t recognize app.terminate().
class DeviceSettingsUtilities : UITestUtilities {
func remo
I'm using the below workaround to terminate the app after last test case of a class.
class BaseClass: XCTestCase {
static var LastTestCaseName: String = ""
override class func setUp() {
LastTestCaseName = defaultTestSuite.tests.last!.name
super.setUp()
}
override func tearDown() {
let app = XCUIApplication()
if BaseClass.LastTestCaseName == testRun?.test.name {
app.terminate()
}
}
}