updating testing code without app state hooks