WinAppDriver: implement /context to support PageFactory @WindowsFindBy annotation
WinAppDriver does not work with @WindowsFindBy annotation because AppiumFieldDecorator forces the GET /context command, which is not supported by WinAppDriver. I understand WinAppDriver does not currently support WebView and therefore it does not support context switching, so /context command is not provided. However, the context switching is not required to support @WindowsFindBy annotated element. It just needs the /context command that returns the current context name, which could be hard-coded as "NATIVE_APP". Then Appium will happily use the native locator.
Hi, Can you provide Java example on how to use AppliumFieldDecorator class with hard-codec context(NATIVE_APP)