FieldPage extends BaseDecisionTableColumnPage<T> { boolean hasEditingPattern() { return !nil(factType()); } @Inject  FieldPage(final View view,
                     final TranslationService translationService); @Override String getTitle(); @Override void isComplete(final Callback<Boolean> callback); @Override void prepareView(); String getFactField();  }
@Test public void testHasEditingPatternWhenFactPatternIsNotNull() throws Exception { when(pattern52.getFactType()).thenReturn("factType"); when(plugin.patternWrapper()).thenReturn(pattern52); assertTrue(page.hasEditingPattern()); }
@Test public void testHasEditingPatternWhenFactPatternIsNull() throws Exception { when(pattern52.getFactType()).thenReturn(""); when(plugin.patternWrapper()).thenReturn(pattern52); assertFalse(page.hasEditingPattern()); }