	@Test
	public void testPreviousItemId() {


		when(service.findIds(isNull(), isNull(), any()))
				.thenReturn(List.of(1, 2, 3));
		provider = new IdBasedDataProvider<>(service, emf.getModel(TestEntity.class));
		provider.size(query);

		provider.setCurrentlySelectedId(2);
		assertTrue(provider.hasPreviousItemId());

		Integer next = provider.getPreviousItemId();
		assertEquals(1, next.intValue());
		assertFalse(provider.hasPreviousItemId());
	}