java.lang.AssertionError: Expected: To be empty but: Request violations: - Body does not match schema for action(POST /products) mime-type('application/json') Content: { "name" : "Motorbike", "price" : 150.0, "weight" : 800 } Message: Schema invalid: Unrecognized token 'product': was expecting ('true', 'false' or 'null') at [Source: Inline schema definition; line: 1, column: 8] Response violations: - Body does not match schema for action(POST /products) response(201) mime-type('application/json') Content: { "name" : "Motorbike", "price" : 150.0, "weight" : 800, "id" : "7fa62cdc-ed3f-493c-893b-41beaffd588f" } Message: Schema invalid: Unrecognized token 'product': was expecting ('true', 'false' or 'null') at [Source: Inline schema definition; line: 1, column: 8]

GitHub | boeboe | 3 months ago
  1. 0

    [Question] support for included schema definitions

    GitHub | 3 months ago | boeboe
    java.lang.AssertionError: Expected: To be empty but: Request violations: - Body does not match schema for action(POST /products) mime-type('application/json') Content: { "name" : "Motorbike", "price" : 150.0, "weight" : 800 } Message: Schema invalid: Unrecognized token 'product': was expecting ('true', 'false' or 'null') at [Source: Inline schema definition; line: 1, column: 8] Response violations: - Body does not match schema for action(POST /products) response(201) mime-type('application/json') Content: { "name" : "Motorbike", "price" : 150.0, "weight" : 800, "id" : "7fa62cdc-ed3f-493c-893b-41beaffd588f" } Message: Schema invalid: Unrecognized token 'product': was expecting ('true', 'false' or 'null') at [Source: Inline schema definition; line: 1, column: 8]
  2. 0

    Windows build fails

    GitHub | 2 years ago | philwebb
    java.lang.AssertionError: Expected: "banner 1 10.2 2.0\n" but: was "banner 1 10.2 2.0\r\n"
  3. 0

    [Socket|Epoll]SslEchoTest failures (unexpected cipher and heap space error)

    GitHub | 2 years ago | Scottmitch
    java.lang.AssertionError: Expected: is "SSL_RSA_WITH_RC4_128_SHA" but: was "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA"
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    java.lang.AssertionError: Expected: a string containing "\"identifier\":" in ca.uhn.fhir.rest.server.ServerFeaturesTest

    GitHub | 1 year ago | pogo61
    java.lang.AssertionError: Expected: a string containing "\"identifier\":" but: was "<Patient xmlns="http://hl7.org/fhir"><identifier><use value="official"/><system value="urn:hapitest:mrns"/><value value="00001"/></identifier><name><family value="Test"/><given value="PatientOne"/></name><gender><text value="M"/></gender></Patient>"
  6. 0

    testAdminCon.getStatements(null, null, null, false, null, dirgraph) fails

    GitHub | 1 year ago | srinathgit
    java.lang.AssertionError: Expected: (is null or is <http://marklogic.com/dirgraph>) but: was <http://marklogic.com/dirgraph1>

  1. cesarnog 1 times, last 2 months ago
  2. qoomon 1 times, last 4 months ago
  3. tfr 1 times, last 5 months ago
  4. andyglick 5 times, last 8 months ago
  5. davidvanlaatum 7 times, last 3 weeks ago
3 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.lang.AssertionError

    Expected: To be empty but: Request violations: - Body does not match schema for action(POST /products) mime-type('application/json') Content: { "name" : "Motorbike", "price" : 150.0, "weight" : 800 } Message: Schema invalid: Unrecognized token 'product': was expecting ('true', 'false' or 'null') at [Source: Inline schema definition; line: 1, column: 8] Response violations: - Body does not match schema for action(POST /products) response(201) mime-type('application/json') Content: { "name" : "Motorbike", "price" : 150.0, "weight" : 800, "id" : "7fa62cdc-ed3f-493c-893b-41beaffd588f" } Message: Schema invalid: Unrecognized token 'product': was expecting ('true', 'false' or 'null') at [Source: Inline schema definition; line: 1, column: 8]

    at org.hamcrest.MatcherAssert.assertThat()
  2. Hamcrest
    MatcherAssert.assertThat
    1. org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
    1 frame
  3. JUnit
    Assert.assertThat
    1. org.junit.Assert.assertThat(Assert.java:956)
    2. org.junit.Assert.assertThat(Assert.java:923)
    2 frames
  4. be.rombit.romcore
    RestVerticleTest.testAddProductEndpoint
    1. be.rombit.romcore.poc.productservice.RestVerticleTest.testAddProductEndpoint(RestVerticleTest.java:67)
    1 frame
  5. Java RT
    DelegatingMethodAccessorImpl.invoke
    1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    3 frames
  6. io.vertx.ext
    VertxUnitRunner$3.evaluate
    1. io.vertx.ext.unit.junit.VertxUnitRunner.invokeTestMethod(VertxUnitRunner.java:95)
    2. io.vertx.ext.unit.junit.VertxUnitRunner.lambda$invokeExplosively$0(VertxUnitRunner.java:114)
    3. io.vertx.ext.unit.impl.TestContextImpl$Step.run(TestContextImpl.java:122)
    4. io.vertx.ext.unit.impl.TestContextImpl$Step.access$600(TestContextImpl.java:30)
    5. io.vertx.ext.unit.impl.TestContextImpl.run(TestContextImpl.java:221)
    6. io.vertx.ext.unit.junit.VertxUnitRunner.invokeExplosively(VertxUnitRunner.java:130)
    7. io.vertx.ext.unit.junit.VertxUnitRunner.access$000(VertxUnitRunner.java:39)
    8. io.vertx.ext.unit.junit.VertxUnitRunner$1.evaluate(VertxUnitRunner.java:84)
    9. io.vertx.ext.unit.junit.VertxUnitRunner$2.evaluate(VertxUnitRunner.java:196)
    10. io.vertx.ext.unit.junit.VertxUnitRunner$3.evaluate(VertxUnitRunner.java:211)
    10 frames
  7. JUnit
    JUnitCore.run
    1. org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
    2. org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
    3. org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
    4. org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
    5. org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
    6. org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
    7. org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
    8. org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
    9. org.junit.runners.ParentRunner.run(ParentRunner.java:363)
    10. org.junit.runner.JUnitCore.run(JUnitCore.java:137)
    10 frames
  8. IntelliJ junit4 module
    JUnit4IdeaTestRunner.startRunnerWithArgs
    1. com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:78)
    1 frame
  9. IDEA
    JUnitStarter.main
    1. com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:212)
    2. com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:68)
    2 frames
  10. Java RT
    NativeMethodAccessorImpl.invoke
    1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    2 frames
  11. IDEA
    AppMain.main
    1. com.intellij.rt.execution.application.AppMain.main(AppMain.java:140)
    1 frame