ScreenshotArgumentBuilder { public ScreenshotArgumentBuilder moveTarget(boolean moveTarget) { setLastAction(Action.MOVE_TARGET); TargetParamHolder holder = getCurrentHolder(); holder.moveTarget = moveTarget; return this; } protected  ScreenshotArgumentBuilder(); protected  ScreenshotArgumentBuilder(String screenshotId); Action getLastAction(); ScreenshotArgument build(); ScreenshotArgumentBuilder screenshotId(String id); ScreenshotArgumentBuilder addNewTarget(); ScreenshotArgumentBuilder addNewTarget(CompareTarget target); ScreenshotArgumentBuilder addNewTarget(ScreenArea target); ScreenshotArgumentBuilder addNewTarget(SelectorType type, String value); ScreenshotArgumentBuilder addNewTargetById(String value); ScreenshotArgumentBuilder addNewTargetByClassName(String value); ScreenshotArgumentBuilder addNewTargetByCssSelector(String value); ScreenshotArgumentBuilder addNewTargetByLinkText(String value); ScreenshotArgumentBuilder addNewTargetByName(String value); ScreenshotArgumentBuilder addNewTargetByPartialLinkText(String value); ScreenshotArgumentBuilder addNewTargetByTagName(String value); ScreenshotArgumentBuilder addNewTargetByXPath(String value); ScreenshotArgumentBuilder addNewTarget(double x, double y, double width, double height); ScreenshotArgumentBuilder addExclude(SelectorType type, String value); ScreenshotArgumentBuilder addExclude(SelectorType type, String value, SelectorType frameSelectorType,
			String frameSelectorValue); ScreenshotArgumentBuilder addExcludeById(String value); ScreenshotArgumentBuilder addExcludeByClassName(String value); ScreenshotArgumentBuilder addExcludeByCssSelector(String value); ScreenshotArgumentBuilder addExcludeByLinkText(String value); ScreenshotArgumentBuilder addExcludeByName(String value); ScreenshotArgumentBuilder addExcludeByPartialLinkText(String value); ScreenshotArgumentBuilder addExcludeByTagName(String value); ScreenshotArgumentBuilder addExcludeByXPath(String value); ScreenshotArgumentBuilder addExclude(ScreenArea exclude); ScreenshotArgumentBuilder addExclude(double x, double y, double width, double height); ScreenshotArgumentBuilder addExcludes(Collection<ScreenArea> excludes); ScreenshotArgumentBuilder addExcludes(ScreenArea... excludes); ScreenshotArgumentBuilder moveTarget(boolean moveTarget); ScreenshotArgumentBuilder scrollTarget(boolean scrollTarget); ScreenshotArgumentBuilder addHiddenElementSelector(SelectorType type, String value); ScreenshotArgumentBuilder addHiddenElementSelector(SelectorType type, String value,
			SelectorType frameSelectorType, String frameSelectorValue); ScreenshotArgumentBuilder addHiddenElementsById(String value); ScreenshotArgumentBuilder addHiddenElementsByClassName(String value); ScreenshotArgumentBuilder addHiddenElementsByCssSelector(String value); ScreenshotArgumentBuilder addHiddenElementsByLinkText(String value); ScreenshotArgumentBuilder addHiddenElementsByName(String value); ScreenshotArgumentBuilder addHiddenElementsByPartialLinkText(String value); ScreenshotArgumentBuilder addHiddenElementsByTagName(String value); ScreenshotArgumentBuilder addHiddenElementsByXPath(String value); ScreenshotArgumentBuilder addHiddenElementSelectors(Collection<DomSelector> selectors); ScreenshotArgumentBuilder addHiddenElementSelectors(DomSelector... selectors); ScreenshotArgumentBuilder inFrame(SelectorType type, String value); ScreenshotArgumentBuilder inFrameById(String value); ScreenshotArgumentBuilder inFrameByClassName(String value); ScreenshotArgumentBuilder inFrameByCssSelector(String value); ScreenshotArgumentBuilder inFrameByLinkText(String value); ScreenshotArgumentBuilder inFrameByName(String value); ScreenshotArgumentBuilder inFrameByPartialLinkText(String value); ScreenshotArgumentBuilder inFrameByTagName(String value); ScreenshotArgumentBuilder inFrameByXPath(String value);  }
@Test public void moveTarget_beforeCall_addNewTarget() throws Exception { ScreenshotArgumentBuilder builder = new ScreenshotArgumentBuilder("ssid"); expected.expect(IllegalStateException.class); expected.expectMessage(containsString("addNewTarget is not called")); builder.moveTarget(false); }