use of com.baeldung.model.Movie in project tutorials by eugenp.
the class RestEasyClientLiveTest method testListAllMovies.
@Test
public void testListAllMovies() {
final ResteasyClient client = new ResteasyClientBuilder().build();
final ResteasyWebTarget target = client.target(FULL_PATH);
final ServicesInterface proxy = target.proxy(ServicesInterface.class);
Response moviesResponse = proxy.addMovie(transformerMovie);
moviesResponse.close();
moviesResponse = proxy.addMovie(batmanMovie);
moviesResponse.close();
final List<Movie> movies = proxy.listMovies();
System.out.println(movies);
}
use of com.baeldung.model.Movie in project tutorials by eugenp.
the class RestEasyClientLiveTest method testMovieByImdbId.
@Test
public void testMovieByImdbId() {
final String transformerImdbId = "tt0418279";
final ResteasyClient client = new ResteasyClientBuilder().build();
final ResteasyWebTarget target = client.target(FULL_PATH);
final ServicesInterface proxy = target.proxy(ServicesInterface.class);
final Response moviesResponse = proxy.addMovie(transformerMovie);
moviesResponse.close();
final Movie movies = proxy.movieByImdbId(transformerImdbId);
System.out.println(movies);
}
Aggregations