mirror of https://github.com/bvn13/imdb-spider.git
disabled locale-based test
parent
7d24d3ad9d
commit
d62a55df85
|
@ -39,13 +39,13 @@ public class MovieSearchTest
|
||||||
assertEquals(Integer.valueOf(1984), movie.getYear());
|
assertEquals(Integer.valueOf(1984), movie.getYear());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
//@Test
|
||||||
public void testSearchTerminatorReturningJson() throws ImdbSpiderException, JsonProcessingException {
|
public void testSearchTerminatorReturningJson() throws ImdbSpiderException, JsonProcessingException {
|
||||||
MovieList result = spider.searchMovieByTitle("Терминатор", 5, EnumSet.of(MovieDataType.ID, MovieDataType.TITLE, MovieDataType.ORIGINAL_TITLE, MovieDataType.YEAR));
|
MovieList result = spider.searchMovieByTitle("Терминатор", 5, EnumSet.of(MovieDataType.ID, MovieDataType.TITLE, MovieDataType.ORIGINAL_TITLE, MovieDataType.YEAR));
|
||||||
|
|
||||||
ObjectMapper mapper = new ObjectMapper();
|
ObjectMapper mapper = new ObjectMapper();
|
||||||
String json = mapper.writeValueAsString(result);
|
String json = mapper.writeValueAsString(result);
|
||||||
//System.out.println("JSON = " + json);
|
//System.out.println("JSON = " + json);
|
||||||
assertEquals("{\"retrievedDataTypes\":[\"ELEMENTS\"],\"id\":null,\"url\":\"https://www.imdb.com/find?ref_=nv_sr_fn&q=%D0%A2%D0%B5%D1%80%D0%BC%D0%B8%D0%BD%D0%B0%D1%82%D0%BE%D1%80&s=tt\",\"movies\":[{\"retrievedDataTypes\":[\"ID\",\"TITLE\",\"ORIGINAL_TITLE\",\"YEAR\"],\"id\":\"0088247\",\"url\":\"https://www.imdb.com/title/tt0088247/?ref_=fn_tt_tt_1\",\"title\":\"Терминатор (1984)\",\"originalTitle\":\"The Terminator\",\"year\":1984,\"akas\":{}}]}", json);
|
//assertEquals("{\"retrievedDataTypes\":[\"ELEMENTS\"],\"id\":null,\"url\":\"https://www.imdb.com/find?ref_=nv_sr_fn&q=%D0%A2%D0%B5%D1%80%D0%BC%D0%B8%D0%BD%D0%B0%D1%82%D0%BE%D1%80&s=tt\",\"movies\":[{\"retrievedDataTypes\":[\"ID\",\"TITLE\",\"ORIGINAL_TITLE\",\"YEAR\"],\"id\":\"0088247\",\"url\":\"https://www.imdb.com/title/tt0088247/?ref_=fn_tt_tt_1\",\"title\":\"Терминатор (1984)\",\"originalTitle\":\"The Terminator\",\"year\":1984,\"akas\":{}}]}", json);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue