-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Running this test in plain mode (I mean, not inside the Android emulator):
@Test
public void mustNotAllowCostsByDefault()
{
final Criteria criteria = (Criteria)fixture.getCriteria();
assertThat(criteria.getAccuracy(), is(Criteria.ACCURACY_FINE));
assertThat(criteria.isAltitudeRequired(), is(false));
assertThat(criteria.isBearingRequired(), is(false));
assertThat(criteria.isCostAllowed(), is(false));
assertThat(criteria.isSpeedRequired(), is(false));
}
I get:
mustNotAllowCostsByDefault(it.tidalwave.bluebill.mobile.android.location.AndroidLocationPreferencesTest)
Time elapsed: 0.031 sec <<< ERROR!
java.lang.RuntimeException: Stub!
at android.location.Criteria.<init>(Criteria.java:5)
at
it.tidalwave.bluebill.mobile.android.location.AndroidLocationPreferences.getCriteria(AndroidLocationPreferences.java:49)
at
it.tidalwave.bluebill.mobile.android.location.AndroidLocationPreferences.getCriteria(AndroidLocationPreferences.java:39)
at
it.tidalwave.bluebill.mobile.android.location.AndroidLocationPreferencesTest.mustNotAllowCostsByDefault(AndroidLocationPreferencesTest.java:53)
Why should I be forced to run this test inside the emulator? It's just
a test of model classes, not depending on the UI (neither on any
service implementation). And Criteria sounds as a simple Java bean, it
was so hard to implement it?
- --
Fabrizio Giudici - Java Architect, Project Manager
Tidalwave s.a.s. - "We make Java work. Everywhere."
java.net/blog/fabriziogiudici - www.tidalwave.it/people
[email protected]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.14 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAkvfOjEACgkQeDweFqgUGxdOVwCfVfDC6Bm3xeh8yNMc+sEuSAD7
m4sAnjsRXwbb+NM9TH3SNi5EQjtto1TQ
=+lE3
-----END PGP SIGNATURE-----
--
You received this message because you are subscribed to the Google Groups "The
Java Posse" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/javaposse?hl=en.