@Test public void testAddCarsFail() { try { List<Car> cars = getValidCars(); cars.get(0).setLicensePlate("xxx123"); cars.get(1).setSeatCount(0); cars.get(1).setManufacturer("XXX"); garageService.addCars(cars); } catch (CarException e) { assertThat(e.getClass().getName(), is(CarException.class.getName())); assertThat(e.getMessage(), is(String.format(CarError.LICENSEPLATE_ERROR.msg(), "xxx123"))); } }
@Override public List<Car> addCars(@FluentValid(NotEmptyValidator.class) List<Car> cars) { System.out.println(cars); return cars; }
GarageServiceImpl2 implements GarageService2 { @Override public List<Car> addCars(@FluentValid(NotEmptyValidator.class) List<Car> cars) { System.out.println(cars); return cars; } }
GarageServiceImpl2 implements GarageService2 { @Override public List<Car> addCars(@FluentValid(NotEmptyValidator.class) List<Car> cars) { System.out.println(cars); return cars; }  }
GarageServiceImpl2 implements GarageService2 { @Override public List<Car> addCars(@FluentValid(NotEmptyValidator.class) List<Car> cars) { System.out.println(cars); return cars; }  @Override List<Car> addCars(@FluentValid(NotEmptyValidator.class) List<Car> cars); @Override List<Car> addCarsThrowException(@FluentValid List<Car> cars); @Override Car addCar(@FluentValid Car car); @Override Garage buildGarage(@FluentValid Garage garage); }
GarageServiceImpl2 implements GarageService2 { @Override public List<Car> addCars(@FluentValid(NotEmptyValidator.class) List<Car> cars) { System.out.println(cars); return cars; }  @Override List<Car> addCars(@FluentValid(NotEmptyValidator.class) List<Car> cars); @Override List<Car> addCarsThrowException(@FluentValid List<Car> cars); @Override Car addCar(@FluentValid Car car); @Override Garage buildGarage(@FluentValid Garage garage);  }