@Test
public void testContentHasNoChangesInDefaultBranch() throws InterruptedException, IOException {

    DockerfileGitHubUtil dockerfileGitHubUtil = mock(DockerfileGitHubUtil.class);
    GHRepository repo = mock(GHRepository.class);
    ForkableRepoValidator validator = new ForkableRepoValidator(dockerfileGitHubUtil);
    GHContent content = mock(GHContent.class);
    String searchContentPath = "/Dockerfile";
    when(content.getPath()).thenReturn(searchContentPath);
    String imageName = "someImage";
    GitForkBranch gitForkBranch = new GitForkBranch(imageName, "someTag", null);
    when(dockerfileGitHubUtil.tryRetrievingContent(eq(repo), any(), any())).thenReturn(content);
    InputStream inputStream = new ByteArrayInputStream("nochanges".getBytes());
    when(content.read()).thenReturn(inputStream);
    assertEquals(validator.contentHasChangesInDefaultBranch(repo, content, gitForkBranch),
            shouldNotForkResult(String.format(COULD_NOT_FIND_IMAGE_TO_UPDATE_TEMPLATE, imageName, searchContentPath)));
}