@Override public boolean setVisibleSizeAndRefresh(int width, int height) { this.previousVisibleWidth = this.visibleWidth; this.visibleWidth = width; this.visibleHeight = height; return refreshWidth(); }
@Override public boolean setVisibleSizeAndRefresh(int width, int height) { this.previousVisibleWidth = this.visibleWidth; this.visibleWidth = width; this.visibleHeight = height; return refreshWidth(); }
@Test public void refreshWidthWithValue() { BaseGridData data = spy(baseGridData); double width = 100; data.refreshWidth(width); verify(data, times(1)) .internalRefreshWidth(booleanArgumentCaptor.capture(), optionalDoubleArgumentCaptor.capture()); assertFalse(booleanArgumentCaptor.getValue()); assertEquals(width, optionalDoubleArgumentCaptor.getValue().getAsDouble(), 0.1); }
@Test public void refreshWidthWithValue() { BaseGridData data = spy(baseGridData); double width = 100; data.refreshWidth(width); verify(data, times(1)) .internalRefreshWidth(booleanArgumentCaptor.capture(), optionalDoubleArgumentCaptor.capture()); assertFalse(booleanArgumentCaptor.getValue()); assertEquals(width, optionalDoubleArgumentCaptor.getValue().getAsDouble(), 0.1); }
@Test public void refreshWidth() { BaseGridData data = spy(baseGridData); data.refreshWidth(); verify(data, times(1)) .internalRefreshWidth(booleanArgumentCaptor.capture(), optionalDoubleArgumentCaptor.capture()); assertFalse(booleanArgumentCaptor.getValue()); assertFalse(optionalDoubleArgumentCaptor.getValue().isPresent()); }
@Test public void refreshWidth() { BaseGridData data = spy(baseGridData); data.refreshWidth(); verify(data, times(1)) .internalRefreshWidth(booleanArgumentCaptor.capture(), optionalDoubleArgumentCaptor.capture()); assertFalse(booleanArgumentCaptor.getValue()); assertFalse(optionalDoubleArgumentCaptor.getValue().isPresent()); }