    @Test
    public void resolveValueTest() throws Exception {

        Map<String, String> env = new HashMap<>();
        env.put("DOCKER_USERNAME", "anuruddhal");
        setEnv(env);
        try {
            Assert.assertEquals(DockerPluginUtils.resolveValue("$env{DOCKER_USERNAME}"), "anuruddhal");
        } catch (DockerPluginException e) {
            Assert.fail("Unable to resolve environment variable");
        }
        try {
            DockerPluginUtils.resolveValue("$env{DOCKER_PASSWORD}");
            Assert.fail("Env value should be resolved");
        } catch (DockerPluginException e) {
            Assert.assertEquals(e.getMessage(), "error resolving value: DOCKER_PASSWORD is not set in the " +
                    "environment.");
        }
        Assert.assertEquals(DockerPluginUtils.resolveValue("demo"), "demo");

    }