@Test(expected = OutOfStockSpaceException.class)
	public void testPickTraysOverfilled() throws OutOfStockSpaceException,
			InconsistencyException, StockNotCompatibleException,
			PickTooEarlyException, PickTooLateException {
		Stock destination = new Stock("Test stock", StockType.SEMI, 1, 16, 1);
		StorageUnit su = new StorageUnit(destination, 0);
		for (int i = 0; i < destination.getMaxTraysPerStorageUnit(); i++) {
			su.addTray(new Tray());
		}
		destination.addStorageUnit(su);
		long t = System.currentTimeMillis();
		Date time = new Date(t);

		ProductType pt = new ProductType("Test Product Type");
		SubProcess sp1 = new SubProcess(0, "Test SP 1", 2, 3, 4), sp2 = new SubProcess(
				1, "Test SP 2", 2, 3, 4);
		sp1.addStock(destination);
		sp2.addStock(destination);
		pt.addSubProcess(sp1);
		pt.addSubProcess(sp2);
		Tray t1 = new Tray(pt);
		Set<Tray> trays = new HashSet<Tray>();
		trays.add(t1);

		GregorianCalendar cal = new GregorianCalendar();
		cal.setTime(time);
		cal.add(GregorianCalendar.MINUTE, 2);

		Service.pickTrays(trays, destination, cal.getTime());
		Assert.assertEquals(1, su.getTrays().size());
		Assert.assertTrue(su.getTrays().contains(t1));
		Assert.assertEquals(t1.getCurrentState().getStartTime(), cal.getTime());

		Assert.fail("Exception not thrown!");
	}