@Test
    public void testParseConfiguration() {
        IPBlacklistPolicy policy = new IPBlacklistPolicy();
        
        // Empty config test
        String config = "{}";
        Object parsed = policy.parseConfiguration(config);
        Assert.assertNotNull(parsed);
        Assert.assertEquals(IPListConfig.class, parsed.getClass());
        IPListConfig parsedConfig = (IPListConfig) parsed;
        Assert.assertNotNull(parsedConfig.getIpList());
        Assert.assertTrue(parsedConfig.getIpList().isEmpty());
        
        // Single IP address
        config = "{" + 
                "  \"httpHeader\" : null," +
                "  \"ipList\" : [" + 
                "    \"1.2.3.4\"" + 
                "  ]" + 
                "}";
        parsed = policy.parseConfiguration(config);
        parsedConfig = (IPListConfig) parsed;
        Assert.assertNotNull(parsedConfig.getIpList());
        Assert.assertEquals(1, parsedConfig.getIpList().size());
        Assert.assertNull(parsedConfig.getHttpHeader());
        Assert.assertEquals("1.2.3.4", parsedConfig.getIpList().iterator().next());

        // Multiple IP addresses
        config = "{" + 
                "  \"httpHeader\" : \"X-Forwarded-For\"," +
                "  \"ipList\" : [" + 
                "    \"1.2.3.4\"," + 
                "    \"3.4.5.6\"," + 
                "    \"10.0.0.11\"" + 
                "  ]" + 
                "}";
        parsed = policy.parseConfiguration(config);
        parsedConfig = (IPListConfig) parsed;
        Assert.assertNotNull(parsedConfig.getIpList());
        Assert.assertEquals("X-Forwarded-For", parsedConfig.getHttpHeader());
        Assert.assertEquals(3, parsedConfig.getIpList().size());
    }
Test method for {@link io.apiman.gateway.engine.policies.IPBlacklistPolicy#parseConfiguration(java.lang.String)}.
gateway/engine/policies/src/test/java/io/apiman/gateway/engine/policies/IPBlacklistPolicyTest.java