Comments (6)
From [email protected] on November 05, 2010 05:07:39
Correct activity did not appear. expected:<...Splash...> but was:<...Home...>
I guess that the Activity that is opened after the splash screen is <...Home...>?
Owner: renasreda
from robotium.
From [email protected] on November 05, 2010 05:14:10
Exactly. I know that using a sleep is not good but I would like to know why this test fails.
Some questions:
- When is solo.assertCurrentActivity executed?
- Leaving the UI thread alone will fix this issue?
from robotium.
From [email protected] on November 05, 2010 05:34:24
It gets executed after the Home activity is active. By the time assertCurrentActivity() gets executed the Splash activity is no longer active. Usually the problem is the opposite. Please see this thread: http://groups.google.com/group/robotium-developers/browse_thread/thread/79a70038c16e35e6/f08a0d9733982a59?lnk=gst&q=getCurrentActivity#f08a0d9733982a59 In both cases there is unfortunately nothing we can do about it. It takes some time for Robotium to load and the activityMonitor to start registering a new Activity. If a new Activity is not registered then it will think that it is still on the Splash activity. In your case the sleep() prevents that and gives time to Robotium to register the new Home activity before assertCurrentActivity() is executed.
Thanks for reporting this. As I said earlier this is a known limitation which we can not do anything about.
Status: WontFix
from robotium.
From [email protected] on November 05, 2010 05:49:46
renasreda: Thanks for your reply.
What would you recommend? Leave the SplashScreen untested?
Thanks.
from robotium.
From [email protected] on November 05, 2010 05:53:57
Yes, that is what I would do. I would use assertCurrentActivity() on the Home activity instead. And then take it from there.
from robotium.
From [email protected] on November 05, 2010 06:05:46
Cool, thanks for the support.
from robotium.
Related Issues (20)
- update repository description URL
- Build error with JavaCompile.setDependencyCacheDir() HOT 4
- Recording failed; Build failed with an exception HOT 3
- Links to PDF tutorials are broken
- Application not launch on test started HOT 4
- ClickOnScreen Not working
- ClickOnwebElement not working
- Build failed: Could not find :ExecutorLibrary: HOT 3
- Is Robotium dead? HOT 4
- CLick on TwoWayView, Viewpager
- robotium typetext wrong order HOT 2
- Cannot find Activity class on Android7.0 HOT 1
- Can't open Javadoc HOT 1
- assertFalse does not work on Android Oreo 8.1 HOT 1
- [QUESTION] Where I can find the CI service?
- Robotium Recorder : Please install a compatible Android API level (15 or higher) HOT 2
- Image validation in mobile native app HOT 2
- Robotium to work with targetSdkVersion 30
- Could not find manifest file within jar
- Could find http://recorder.robotium.com/updates
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from robotium.