Skip to content

Instantly share code, notes, and snippets.

@brunokrebs
Last active March 10, 2016 13:13
Show Gist options
  • Save brunokrebs/c5600d8359770979ecaf to your computer and use it in GitHub Desktop.
Save brunokrebs/c5600d8359770979ecaf to your computer and use it in GitHub Desktop.
package br.com.brunokrebs;
// ... previously added imports...
import static com.jayway.restassured.RestAssured.when;
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
// we need the above annotation to make test1CreateUser run before test2ListUsers
public class UserRestIT {
// ... previously defined constant and test ...
@Test
public void test2ListUsers() {
when().get(USER_ENDPOINT).then()
.body("[0].name", equalTo("Bruno Krebs"))
.body("[0].email", equalTo("[email protected]"));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment