public boolean shouldShow(@Nullable Keyboard.Key pressedKey) {
    return pressedKey != null && shouldShow(pressedKey.getPrimaryCode());
  }
@Test
  public void testHappyPath() {
    final OnKeyWordHelper helper = new OnKeyWordHelper("test".toCharArray());

    Keyboard.Key key = Mockito.mock(Keyboard.Key.class);

    Mockito.doReturn((int) 't').when(key).getPrimaryCode();
    Assert.assertFalse(helper.shouldShow(key));
    Mockito.doReturn((int) 'e').when(key).getPrimaryCode();
    Assert.assertFalse(helper.shouldShow(key));
    Mockito.doReturn((int) 's').when(key).getPrimaryCode();
    Assert.assertFalse(helper.shouldShow(key));
    Mockito.doReturn((int) 't').when(key).getPrimaryCode();
    Assert.assertTrue(helper.shouldShow(key));

    Mockito.doReturn((int) 't').when(key).getPrimaryCode();
    Assert.assertFalse(helper.shouldShow(key));
    Mockito.doReturn((int) 'e').when(key).getPrimaryCode();
    Assert.assertFalse(helper.shouldShow(key));
    Mockito.doReturn((int) 's').when(key).getPrimaryCode();
    Assert.assertFalse(helper.shouldShow(key));
    Mockito.doReturn((int) 't').when(key).getPrimaryCode();
    Assert.assertTrue(helper.shouldShow(key));
  }