I have created a Java-Cucumber framework, which uses Cucumber-JVM, appium, java, maven for running automation scenarios on ReactNative driven App. So, using ReactNative we've Android & iOS apps.
The framework is based on Selenium Multibrowser concept, where driver once instanciated ( for a browser) can make use of existing page objects.
Issue 1: Whereas in case of Mobile, Although Page Object methods are same, but locators for IOS & Android are different. [I have not used Page factory (@Findby annotations) So, I would like to know how could I reuse the page object methods written of the iOS, for Android? Issue 2: I have used Pico-Container for seeding Page objects into Step-defs. World is instanciated in BaseClass which is parent class of both Android & iOS Stepdefs. But If I invoke, page objectmager in Android step defs then getting NullPointer exception.
Issue 3: Using Cucumber how to reuse the step-defs implementation of the iOS for Android?
We use Singleton pattern for Appium driver instantiation.