Since, XCTest requires its instances to launch with a code snippet like this :
let app = XCUIApplication()
let device = XCUIDevice()
app.launch()
and EarlGrey initialises the app instance in a different way. So when I tried to intertwine both code, tests failed, because the underlying hook is not able to switch between both of them. Can you please suggest me how to proceed with this?