Giter VIP home page Giter VIP logo

Comments (3)

jam-le avatar jam-le commented on May 23, 2024 1

I found out what the issue was today. Using anything other than JDK 1.8 (including later versions from 10 and upwards, I believe) will cause Robolectric to break. Hence the failing unit tests. I couldn't figure out why my build wasn't working because I set JAVA_HOME=/path-to-my-1.8-jdk. Turns out I wasn't setting the correct folder. On my Mac, "/bin/java" is automatically appended to the JAVA_HOME variable, apparently, so you have to get the pathname correct taking into account the appended string.

(As an aside, I would suggest instructions in the tutorial for how to permanently set the JAVA_HOME variable or link to some documentation explaining this. Basically, for Mac, you just sudo nano ~./bash_profile and add export JAVA_HOME='path-to-jdk-1.8' into the file that opens. Save and exit the file and the JAVA_HOME variable should be set to the value you specified every time you open a terminal).

I will leave this open in case this issue of JDK 10, 11, 12, and 13 incompatibility still needs to be tracked.

from kampkit.

samhill303 avatar samhill303 commented on May 23, 2024

Thanks for the issue, I'm glad you got it working. We do want to find the best way to deal with JDK discrepancies. There is a similar issue here: #44

from kampkit.

russhwolf avatar russhwolf commented on May 23, 2024

We've upgraded to use Robolectric 4.3. That seemed to fix the case where I'd seen this issue. Interested to know if it still happens for anyone else.

from kampkit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.