@Test public void testBuildCoupe() { testCar = new Sport(new TurboEngine(1800)); testCarBuilder = new CarBuilder(testCar); instance.build(testCarBuilder); Vehicle getVehicle = testCarBuilder.getVehicle(); assertEquals(getVehicle, testCar); }
@Test public void testBuildSaloon() { testCar = new Saloon(new StandardEngine(1300)); testCarBuilder = new CarBuilder(testCar); instance.build(testCarBuilder); Vehicle getVehicle = testCarBuilder.getVehicle(); assertEquals(getVehicle, testCar); }