### Question:
EncodingManager implements EncodedValueLookup { public static EncodingManager create(String flagEncodersStr) { return create(new DefaultFlagEncoderFactory(), flagEncodersStr); } private  EncodingManager(); static EncodingManager create(String flagEncodersStr); static EncodingManager create(FlagEncoderFactory factory, String flagEncodersStr); static EncodingManager create(FlagEncoder... flagEncoders); static EncodingManager create(List<? extends FlagEncoder> flagEncoders); static EncodingManager create(EncodedValueFactory evFactory, FlagEncoderFactory flagEncoderFactory, String ghLoc); static Builder start(); void releaseParsers(); int getIntsForFlags(); boolean isEnableInstructions(); boolean hasEncodedValue(String key); boolean hasEncoder(String encoder); FlagEncoder getEncoder(String name); boolean acceptWay(ReaderWay way, AcceptWay acceptWay); IntsRef handleRelationTags(ReaderRelation relation, IntsRef relFlags); void handleTurnRelationTags(OSMTurnRelation turnRelation, TurnCostParser.ExternalInternalMap map, Graph graph); IntsRef handleWayTags(ReaderWay way, AcceptWay acceptWay, IntsRef relationFlags); @Override String toString(); String toFlagEncodersAsString(); String toEncodedValuesAsString(); IntsRef createEdgeFlags(); IntsRef createRelationFlags(); IntsRef flagsDefault(boolean forward, boolean backward); @Override boolean equals(Object o); @Override int hashCode(); long handleNodeTags(ReaderNode node); void applyWayTags(ReaderWay way, EdgeIteratorState edge); List<FlagEncoder> fetchEdgeEncoders(); boolean needsTurnCostsSupport(); List<BooleanEncodedValue> getAccessEncFromNodeFlags(long importNodeFlags); @Override BooleanEncodedValue getBooleanEncodedValue(String key); @Override IntEncodedValue getIntEncodedValue(String key); @Override DecimalEncodedValue getDecimalEncodedValue(String key); @Override @SuppressWarnings("unchecked") EnumEncodedValue<T> getEnumEncodedValue(String key, Class<T> type); @Override T getEncodedValue(String key, Class<T> encodedValueType); static String getKey(FlagEncoder encoder, String str); static String getKey(String prefix, String str);  }### Answer:
@Test public void testWrongEncoders() { try { FootFlagEncoder foot = new FootFlagEncoder(); EncodingManager.create(foot, foot); fail("There should have been an exception"); } catch (Exception ex) { assertEquals("You must not register a FlagEncoder (foot) twice or for two EncodingManagers!", ex.getMessage()); } }