jgritman / httpbuilder

315 stars 154 forks source link

Checked out http-builder-0.7.2, mvn install. Tests fail: #33

Open justin-calleja opened 10 years ago

justin-calleja commented 10 years ago

After checking out http-builder-0.7.2 tag, running mvn install gives:

Results :

Failed tests: RESTClientTest.testHead:45 assert ex.response.status == 404 | | | | | | 400 false | groovyx.net.http.HttpResponseDecorator@33182c98 groovyx.net.http.HttpResponseException: Bad Request

Tests in error: AsyncHTTPBuilderTest.testPostAndDelete:108 » Execution org.codehaus.groovy.run... HTTPBuilderTest.testPOST:157 » HttpResponse Bad Request HttpURLClientTest.testPOST:133 » HttpResponse Bad Request HttpURLClientTest.testParsers:183 » HttpResponse Bad Request RESTClientTest.testQueryParameters:125 » HttpResponse Bad Request RESTClientTest.testGet:56 » HttpResponse Bad Request RESTClientTest.testPost:68 » HttpResponse Bad Request RESTClientTest.testDelete:85 » IllegalState No post ID from testPost() RESTClientTest.testDefaultHandlers:109 » HttpResponse Bad Request GAETest.testPOST:184 » HttpResponse Bad Request

Tests run: 80, Failures: 1, Errors: 10, Skipped: 9

[INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE


This works though: mvn install -DskipTests

MateusAmin commented 9 years ago

Hey justin-calleja, Did you ever figure out why the tests were failing?

MateusAmin commented 9 years ago

Test set: groovyx.net.http.HttpURLClientTest

Tests run: 11, Failures: 1, Errors: 2, Skipped: 1, Time elapsed: 1.888 sec <<< FAILURE! - in groovyx.net.http.HttpURLClientTest testRedirect(groovyx.net.http.HttpURLClientTest) Time elapsed: 0.471 sec <<< FAILURE! org.codehaus.groovy.runtime.powerassert.PowerAssertionError: assert resp.statusLine.statusCode == 200 | | | | | | 302 false | HTTP/1.1 302 Found groovyx.net.http.HttpResponseDecorator@88b4ed49 at org.codehaus.groovy.runtime.InvokerHelper.assertFailed(InvokerHelper.java:386) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.assertFailed(ScriptBytecodeAdapter.java:658) at groovyx.net.http.HttpURLClientTest.testRedirect(HttpURLClientTest.groovy:49)

testPOST(groovyx.net.http.HttpURLClientTest) Time elapsed: 0.497 sec <<< ERROR! groovyx.net.http.HttpResponseException: Bad Request at groovyx.net.http.HttpURLClient.request(HttpURLClient.java:248) at groovyx.net.http.HttpURLClient$request.call(Unknown Source) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116) at groovyx.net.http.HttpURLClientTest.testPOST(HttpURLClientTest.groovy:133)

testParsers(groovyx.net.http.HttpURLClientTest) Time elapsed: 0.114 sec <<< ERROR! groovyx.net.http.HttpResponseException: Bad Request at groovyx.net.http.HttpURLClient.request(HttpURLClient.java:248) at groovyx.net.http.HttpURLClient$request.call(Unknown Source) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116) at groovyx.net.http.HttpURLClientTest.testParsers(HttpURLClientTest.groovy:183)

justincalleja commented 9 years ago

@MateusAmin , sorry no idea. I'm not sure if I even ended up using this library (it seems the build works - the tests don't). It must have been a minor thing I used this for.

jja commented 8 years ago

See #46 for an analysis of the testRedirect failure