Created
October 4, 2010 15:24
-
-
Save livando/609870 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class HelloAndroidTest extends ActivityInstrumentationTestCase2<Hello> { | |
private Hello mActivity; | |
private TextView mView; | |
private String resourceString; | |
public HelloAndroidTest() { | |
super("com.livando.hello", Hello.class); | |
} | |
@Override | |
protected void setUp() throws Exception { | |
super.setUp(); | |
mActivity = this.getActivity(); | |
mView = (TextView) mActivity.findViewById(com.livando.hello.R.id.textview); | |
resourceString = mActivity.getString(com.livando.hello.R.string.hello); | |
} | |
public void testPreconditions(){ | |
assertNotNull(mView); | |
} | |
public void testText(){ | |
assertEquals(resourceString, mView.getText()); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment