[aerogear-dev] [aerogear-android] Skip SQLStoreTest when running on OSX and Java 1.7

Daniel Passos daniel at passos.me
Mon Dec 2 12:09:20 EST 2013


I'm not sure if this is the best solution but agreed with workaround for now.

-- 
Daniel Passos


On November 22, 2013 at 3:41:23 PM, Tadeas Kriz (tkriz at redhat.com) wrote:

Hey,

I’ve been investigating the issue with SQLStore testing through Robolectric and this is what I’ve found.

Those tests run correctly on linux with both Java 1.6 and Java 1.7 and also works on Mac OS X with Java 1.6. This unfortunately doesn’t apply for the Java 1.7 on Mac and the test is failing. And because I think that this test should definitely not be @Ignore-d all the time, I’ve come up with following solution.

In JUnit, there’s a way to decide whether to run a test or not in runtime, based on org.junit.Assume. This way, we could easily ignore the SQLStoreTest when running on Mac OS X with Java 1.7, but leave it on other platforms. I’ve already taken the liberty to write this down and I’ve bundled it into the PR [1] which is fixing the doubly-called Callback#onSuccess bug (AGDROID-150).

What do you guys think about this solution, or should I say workaround? Of course it’s not perfect, it would be cool if we could run even the SQLStoreTest on all platforms without any difference, but right now it seems to be a incompatibility of SQLite with Mac’s Java 1.7.

1 - https://github.com/aerogear/aerogear-android/pull/120

—
Tadeas Kriz
tkriz at redhat.com

_______________________________________________  
aerogear-dev mailing list  
aerogear-dev at lists.jboss.org  
https://lists.jboss.org/mailman/listinfo/aerogear-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/aerogear-dev/attachments/20131202/986e5082/attachment.html 


More information about the aerogear-dev mailing list