@Test
public void testIsFormAvailableForLoggedUser() throws Exception {

	DDMFormInstance ddmFormInstance = mockDDMFormInstance();
	when(
		_ddmFormInstanceLocalService.fetchFormInstance(Matchers.anyLong())
	).thenReturn(
		ddmFormInstance
	);
	when(
		_ddmFormInstanceService.fetchFormInstance(Matchers.anyLong())
	).thenReturn(
		ddmFormInstance
	);
	DDMFormDisplayContext ddmFormDisplayContext =
		createDDMFormDisplayContext();
	Assert.assertTrue(ddmFormDisplayContext.isFormAvailable());
}