test_class.file: CodeSmells/src/machine/ReportTest.java
test_class.identifier: ReportTest
test_case.body: @Test
  	public void testReport() throws IOException {
  		ArrayList<Machine> line = new ArrayList<Machine>();
  		line.add(new Machine("mixer", "left"));
  
  		Machine extruder = new Machine("extruder", "center");
  		extruder.put("paste");
  		line.add(extruder);
  
  		Machine oven = new Machine("oven", "right");
  		oven.put("chips");
  		line.add(oven);
  
  		Robot robot = new Robot();
  		robot.moveTo(extruder);
  		robot.pick();
  
  		StringWriter out = new StringWriter();
  		Report.report(out, line, robot);
  
  		String expected = "FACTORY REPORT\n"
  				+ "Machine mixer\nMachine extruder\n"
  				+ "Machine oven bin=chips\n\n"
  				+ "Robot location=extruder bin=paste\n" + "========\n";
  
  		assertEquals(expected, out.toString());
  	}
test_case.class_method_signature: ReportTest.testReport()
test_case.full_signature: @Test public void testReport()
test_case.identifier: testReport
test_case.invocations: add put add put add moveTo pick report assertEquals toString
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testReport()
focal_class.file: CodeSmells/src/machine/Report.java
focal_class.identifier: Report
focal_class.class_method_signature: Report.report(Writer out, List<Machine> machines, Robot robot)
focal_class.full_signature: public static void report(Writer out, List<Machine> machines, Robot robot)
focal_class.identifier: report
focal_class.modifiers: public static
focal_class.parameters: (Writer out, List<Machine> machines, Robot robot)
focal_class.return: void
focal_class.signature: void report(Writer out, List<Machine> machines, Robot robot)
focal_method.body: public static void report(Writer out, List<Machine> machines, Robot robot)
              throws IOException 
      {
          out.write("FACTORY REPORT\n");
  
          Iterator<Machine> line = machines.iterator();
          while (line.hasNext()) {
              Machine machine = line.next();
              out.write("Machine " + machine.name());
  
              if (machine.bin() != null)
                  out.write(" bin=" + machine.bin());
  
              out.write("\n");
          }
          out.write("\n");
  
          out.write("Robot");
          if (robot.location() != null)
              out.write(" location=" + robot.location().name());
  
          if (robot.bin() != null)
              out.write(" bin=" + robot.bin());
  
          out.write("\n");
  
          out.write("========\n");
      }
focal_method.class_method_signature: Report.report(Writer out, List<Machine> machines, Robot robot)
focal_method.full_signature: public static void report(Writer out, List<Machine> machines, Robot robot)
focal_method.identifier: report
focal_method.invocations: write iterator hasNext next write name bin write bin write write write location write name location bin write bin write write
focal_method.modifiers: public static
focal_method.parameters: (Writer out, List<Machine> machines, Robot robot)
focal_method.return: void
focal_method.signature: void report(Writer out, List<Machine> machines, Robot robot)