@VisibleForTesting
  static ImageMetadataOutput fromJson(String json) throws IOException {
    return JsonTemplateMapper.readJson(json, ImageMetadataOutput.class);
  }
@Test
  public void testFromJson() throws IOException {
    ImageMetadataOutput output = ImageMetadataOutput.fromJson(TEST_JSON);
    Assert.assertEquals("gcr.io/project/image:tag", output.getImage());
    Assert.assertEquals(
        "sha256:61bb3ec31a47cb730eb58a38bbfa813761a51dca69d10e39c24c3d00a7b2c7a9",
        output.getImageId());
    Assert.assertEquals(
        "sha256:3f1be7e19129edb202c071a659a4db35280ab2bb1a16f223bfd5d1948657b6fc",
        output.getImageDigest());
    Assert.assertTrue(output.isImagePushed());

    Assert.assertEquals(ImmutableList.of("latest", "tag"), output.getTags());
  }