android - Robotium test framework error -


i new robotium test framework. have created 1 sample project in moving 1 activity other on click of button.

my test case works fine gets crash when comes second activity..

my testcase code

public void testdisplayblackbox() {     solo.clickonbutton("button");     solo.assertcurrentactivity("expected mainactivity activity", "secondactvity");     } 

i getting following error

junit.framework.comparisonfailure: expected mainactivity activity expected:<secondact[]vity> was:<secondact[i]vity> @ com.jayway.android.robotium.solo.asserter.assertcurrentactivity(asserter.java:41) @ com.jayway.android.robotium.solo.solo.assertcurrentactivity(solo.java:588) @ com.example.ddd.mainactivitytest.testdisplayblackbox(mainactivitytest.java:28) @ java.lang.reflect.method.invokenative(native method) @ android.test.instrumentationtestcase.runmethod(instrumentationtestcase.java:214) @ android.test.instrumentationtestcase.runtest(instrumentationtestcase.java:199) @ android.test.activityinstrumentationtestcase2.runtest(activityinstrumentationtestcase2.java:192) @ android.test.androidtestrunner.runtest(androidtestrunner.java:190) @ android.test.androidtestrunner.runtest(androidtestrunner.java:175) @ android.test.instrumentationtestrunner.onstart(instrumentationtestrunner.java:555) @ android.app.instrumentation$instrumentationthread.run(instrumentation.java:1661) 

its not crashing after going second activity closes activity2 normal behavior if want see previous action use solo.goback()


Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

node.js - Bad Request - node js ajax post -

uitableview - Create and use custom prototype table cells in xamarin ios using storyboard -