@Test
    public void testUnannotatedEnumBadOrder() {

        try {

            new EnumGuacamoleProperty<Vegetable>(
                    "potato", Vegetable.POTATO,
                    Vegetable.CARROT, "carrot"
            ) {

                @Override
                public String getName() {
                    return "favorite-vegetable";
                }

            };

            fail("EnumGuacamoleProperty should not accept key/value pairs in value/key order.");

        }
        catch (IllegalArgumentException e) {
            // Success
        }

    }
Verifies that an IllegalArgumentException is thrown if key/value pairs
are provided in the wrong order (value followed by key instead of key
followed by value).
guacamole-ext/src/test/java/org/apache/guacamole/properties/EnumGuacamolePropertyTest.java