@Test(dataProvider = "hasBaseImageData") public void testHasBaseImage(String fromInstruction, String imageToFind, boolean expectedResult) { assertEquals(new FromInstruction(fromInstruction).hasBaseImage(imageToFind), expectedResult); }
public boolean hasBaseImage(String imageToFind) { return baseImageName != null && imageToFind != null && baseImageName.endsWith(imageToFind); }
FromInstruction { public boolean hasBaseImage(String imageToFind) { return baseImageName != null && imageToFind != null && baseImageName.endsWith(imageToFind); } }
FromInstruction { public boolean hasBaseImage(String imageToFind) { return baseImageName != null && imageToFind != null && baseImageName.endsWith(imageToFind); } FromInstruction(String fromInstructionLine); private  FromInstruction(String baseImageName, String tag, List<String> additionalParts, String comments); }
FromInstruction { public boolean hasBaseImage(String imageToFind) { return baseImageName != null && imageToFind != null && baseImageName.endsWith(imageToFind); } FromInstruction(String fromInstructionLine); private  FromInstruction(String baseImageName, String tag, List<String> additionalParts, String comments); static boolean isFromInstructionWithThisImageAndOlderTag(String lineInFile, String imageName, String imageTag); FromInstruction getFromInstructionWithNewTag(String newTag); static boolean isFromInstruction(String dockerFileLine); @Override String toString(); String getBaseImageName(); boolean hasBaseImage(String imageToFind); boolean hasTag(); boolean hasADifferentTag(String expectedTag); String getTag(); List<String> getAdditionalParts(); boolean hasComments(); String getComments(); }
FromInstruction { public boolean hasBaseImage(String imageToFind) { return baseImageName != null && imageToFind != null && baseImageName.endsWith(imageToFind); } FromInstruction(String fromInstructionLine); private  FromInstruction(String baseImageName, String tag, List<String> additionalParts, String comments); static boolean isFromInstructionWithThisImageAndOlderTag(String lineInFile, String imageName, String imageTag); FromInstruction getFromInstructionWithNewTag(String newTag); static boolean isFromInstruction(String dockerFileLine); @Override String toString(); String getBaseImageName(); boolean hasBaseImage(String imageToFind); boolean hasTag(); boolean hasADifferentTag(String expectedTag); String getTag(); List<String> getAdditionalParts(); boolean hasComments(); String getComments();  }