I’m using Robot Framework and AppiumLibrary to test an app on Android and iOS. The problem is that when opening the app with capability noReset=False
all app data is cleared between each test case. The data should only be cleared between each test suite (Quit Application
).
According to best practice from AppiumLibrary you should use Quit Application
/ Launch Application
between each test case to re-start the app.
http://serhatbolsu.github.io/robotframework-appiumlibrary/AppiumLibrary.html#Launch%20Application
The problem is that on Android all information entered in the first test case is cleared when the second test case is launched.
*** Settings ***
Suite Setup Open Application
Suite Teardown Close Application
Test Setup Launch Application
Test Teardown Quit Application
*** Test Cases ***
First Test
Input Text Hello World
Second Test
Page Should Contain Text Hello World
Second Test above will work on iOS but fail on Android. Is this intended or is there some way to avoid this behaviour?
These are the capabilities I’m using:
self.open_application('http://10.246.121.241:4723/wd/hub',
alias='MiniVoc',
app='se.volvo.androidvoc',
appActivity='se.volvo.androidvoc.ui.main.MainActivity',
appWaitActivity='se.volvo.androidvoc.ui.certificates.CertificatesActivity',
autoAcceptAlerts=True,
automationName='Appium',
deviceName='P20',
newCommandTimeout=60,
noReset=False,
platformName='Android',
platformVersion='8.0.0',
udid='9WVDU18C2600668',
wdaLocalPort=8101)