elvyssoares

LoggingTest - Original

May 19th, 2020
145
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.94 KB | None | 0 0
  1. @Test
  2. public void saveImage_noImageFile_ko() throws IOException {
  3.     File outputFile = File.createTempFile("prefix", "png", new File("/tmp"));    
  4.     ProductImage image = new ProductImage("01010101010101",
  5.                                           ProductImageField.FRONT,
  6.                                           outputFile);    
  7.     Response response = serviceWrite.saveImage(image.getCode(),
  8.                                                image.getField(),
  9.                                                image.getImguploadFront(),
  10.                                                image.getImguploadIngredients(),
  11.                                                image.getImguploadNutrition())
  12.                                                .execute();                                              
  13.     assertTrue(response.isSuccess());    
  14.     assertThatJson(response.body())
  15.         .node("status")
  16.         .isEqualTo("status not ok");
  17. }
Advertisement
Add Comment
Please, Sign In to add comment