WebElementListGenerator { public String size() { return callingCommand + "(" + passedValue + ").size()"; } WebElementListGenerator(String command, String value);  WebElementListGenerator(String command); String size(); String toString();  }
@Test public void checkWebElementListSizeReturnsCorrectCode() { assertThat(driver.findElements(locator).size(), is(equalTo("driver.findElements(" + locator + ").size()"))); }