### Question:
Flamingos2Support implements ITccInstrumentSupport { public String getWavelength() { Flamingos2 inst = (Flamingos2) _oe.getInstrument(); Option<Double> wavelength = inst.getObservingWavelength(); if (wavelength.isEmpty()) return DEFAULT_WAVELENGTH; return Double.toString(wavelength.getValue()); } private  Flamingos2Support(ObservationEnvironment oe); static ITccInstrumentSupport create(ObservationEnvironment oe); String getWavelength(); String getPositionAngle(); String getTccConfigInstrument(); String getTccConfigInstrumentOrigin(); String getFixedRotatorConfigName(); void addGuideDetails(ParamSet guideConfig); String getChopState();  }### Answer:
@SuppressWarnings({"ResultOfMethodCallIgnored","unchecked","rawtypes"}) @Test public void testWavelength() throws Exception { final Flamingos2 flam2 = getInstrument(); flam2.setFilter(Filter.OPEN); flam2.setDisperser(Disperser.NONE); setInstrument(flam2); assertEquals("1.6", getWavelength(getSouthResults())); flam2.setFilter(Filter.OPEN); final Pair<Disperser,String>[] dtA = new Pair[] { new Pair<>(Disperser.R1200JH, "1.39"), new Pair<>(Disperser.R1200HK, "1.871"), new Pair<>(Disperser.R3000, "1.65"), }; for (final Pair<Disperser, String> t : dtA) { flam2.setDisperser(t._1()); setInstrument(flam2); assertEquals(t._2(), getWavelength(getSouthResults())); } flam2.setDisperser(Disperser.R3000); final Pair<Filter,String>[] ftA = new Pair[] { new Pair<>(Filter.Y, "1.02"), new Pair<>(Filter.J_LOW, "1.15"), new Pair<>(Filter.J, "1.25"), new Pair<>(Filter.H, "1.65"), new Pair<>(Filter.K_LONG, "2.2" ), new Pair<>(Filter.K_SHORT, "2.15"), new Pair<>(Filter.K_BLUE, "2.06"), new Pair<>(Filter.K_RED, "2.31"), new Pair<>(Filter.JH, "1.39"), new Pair<>(Filter.HK, "1.871"), }; for (final Pair<Filter, String> t : ftA) { flam2.setFilter(t._1()); setInstrument(flam2); assertEquals(t._2(), getWavelength(getSouthResults())); } flam2.setDisperser(Disperser.NONE); for (final Pair<Filter, String> t : ftA) { flam2.setFilter(t._1()); setInstrument(flam2); assertEquals(t._2(), getWavelength(getSouthResults())); } flam2.setFilter(Filter.DARK); setInstrument(flam2); try { Double.parseDouble(getWavelength(getSouthResults())); } catch (final Exception ex) { fail("dark wavelength not set"); } }