Note that there are some explanatory texts on larger screens.

plurals
  1. POUnable to load dependency in Play framework project
    primarykey
    data
    text
    <p>I am trying to use a library called REST Assured with the Play Framework. The documentation - <a href="https://code.google.com/p/rest-assured/wiki/GettingStarted" rel="nofollow">https://code.google.com/p/rest-assured/wiki/GettingStarted</a> - gives the following artifact for Maven - </p> <pre><code>&lt;dependency&gt; &lt;groupId&gt;com.jayway.restassured&lt;/groupId&gt; &lt;artifactId&gt;rest-assured&lt;/artifactId&gt; &lt;version&gt;1.8.0&lt;/version&gt; &lt;scope&gt;test&lt;/scope&gt; &lt;/dependency&gt; </code></pre> <p>So I altered my Build.scala file as follows to include this dependency -</p> <pre><code> val appDependencies = Seq( // Add your project dependencies here, javaCore, javaJdbc, javaEbean, "com.jayway.restassured" % "rest-assured" % "1.8.0" % "test" ) </code></pre> <p>Then I try and use this library in a Java by statically importing some packages, which is what the documentation instructs me to do -</p> <pre><code>import static com.jayway.restassured.RestAssured.*; import static com.jayway.restassured.matcher.RestAssuredMatchers.*; import static org.hamcrest.Matchers.*; </code></pre> <p>But this results in an Compilation error when I try and run the Play application - </p> <blockquote> <p>error: package com.jayway.restassured does not exist</p> </blockquote> <p>I know that Play/sbt is retrieving the dependency because I can see a "com.jayway.restassured" directory in the play-2.1.0/repository/cache directory. However it is not showing in the play-2.1.0/repository/local directory, I don't know if that has any significance.</p> <p>So what's going wrong, why can't I access this library in my Play application?</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload