### Question:
InstructionList implements Iterable<Instruction> { public String createGPX() { return createGPX("GraphHopper", new Date().getTime()); } private  InstructionList();  InstructionList( Translation tr );  InstructionList( int cap, Translation tr ); void replaceLast( Instruction instr ); void add( Instruction instr ); int getSize(); int size(); List<Map<String, Object>> createJson(); boolean isEmpty(); @Override Iterator<Instruction> iterator(); Instruction get( int index ); @Override String toString(); List<GPXEntry> createGPXList(); String createGPX(); String createGPX( String trackName, long startTimeMillis ); String createGPX( String trackName, long startTimeMillis, boolean includeElevation ); Instruction find( double lat, double lon, double maxDistance ); static final InstructionList EMPTY; }### Answer:
@Test public void testCreateGPX() { InstructionAnnotation ea = InstructionAnnotation.EMPTY; InstructionList instructions = new InstructionList(usTR); PointList pl = new PointList(); pl.add(49.942576, 11.580384); pl.add(49.941858, 11.582422); instructions.add(new Instruction(Instruction.CONTINUE_ON_STREET, "temp", ea, pl).setDistance(240).setTime(15000)); pl = new PointList(); pl.add(49.941575, 11.583501); instructions.add(new Instruction(Instruction.TURN_LEFT, "temp2", ea, pl).setDistance(25).setTime(4000)); pl = new PointList(); pl.add(49.941389, 11.584311); instructions.add(new Instruction(Instruction.TURN_LEFT, "temp2", ea, pl).setDistance(25).setTime(3000)); instructions.add(new FinishInstruction(49.941029, 11.584514, 0)); List<GPXEntry> result = instructions.createGPXList(); assertEquals(5, result.size()); assertEquals(0, result.get(0).getTime()); assertEquals(10391, result.get(1).getTime()); assertEquals(15000, result.get(2).getTime()); assertEquals(19000, result.get(3).getTime()); assertEquals(22000, result.get(4).getTime()); verifyGPX(instructions.createGPX()); }