is it ok to switch to app frame here?
previous implementation did that in test code.