@Test
public void testHandleServiceEnvWithExistingEnvsAndNewEnvsWithoutEquals() {

  Map<String, String> existingEnvs = Maps.newHashMap(
      ImmutableMap.<String, String>builder().
          put("a", "1").
          put("b", "2").
          build());
  ImmutableList<String> newEnvs = ImmutableList.of("c3", "d4");
  Service service = createServiceWithEnvVars(existingEnvs);
  org.apache.hadoop.conf.Configuration yarnConfig =
      createYarnConfigWithSecurityValue("kerberos");
  EnvironmentUtilities.handleServiceEnvs(service, yarnConfig, newEnvs);
  Map<String, String> resultEnvs = service.getConfiguration().getEnv();
  assertEquals(5, resultEnvs.size());
  assertEquals("/etc/passwd:/etc/passwd:ro,/etc/group:/etc/group:ro,/etc/krb5.conf:/etc/krb5.conf:ro",
      resultEnvs.get(EnvironmentUtilities.ENV_DOCKER_MOUNTS_FOR_CONTAINER_RUNTIME));
  assertEquals("1", resultEnvs.get("a"));
  assertEquals("2", resultEnvs.get("b"));
  assertEquals("", resultEnvs.get("c3"));
  assertEquals("", resultEnvs.get("d4"));
}