@Test
    public void test_that_leaf_types_are_serialized_to_json_types() {
        SimpletypesConfig.Builder builder = new SimpletypesConfig.Builder();
        builder.boolval(false);
        builder.stringval("foo");
        builder.intval(13);
        builder.longval(14);
        builder.doubleval(3.14);
        builder.enumval(SimpletypesConfig.Enumval.Enum.VAL2);

        final SimpletypesConfig config = new SimpletypesConfig(builder);
        final String expectedJson = inputJson(
                "{",
                "    'boolval': false,",
                "    'doubleval': 3.14,",
                "    'enumval': 'VAL2',",
                "    'intval': 13,",
                "    'longval': 14,",
                "    'stringval': 'foo'",
                "}"
        );

        assertConfigEquals(expectedJson, config);
    }
@author Ulf Lilleengen
@author Vegard Sjonfjell
config/src/test/java/com/yahoo/config/subscription/ConfigInstanceSerializerTest.java