@Test
public void withScreenshotId() throws Exception {

	CompareTarget[] targets = { new CompareTarget(), new CompareTarget(ScreenArea.of(SelectorType.ID, "id")) };
	DomSelector[] selectors = { new DomSelector(SelectorType.ID, "id"),
			new DomSelector(SelectorType.CLASS_NAME, "class") };
	ScreenshotArgument arg = new ScreenshotArgument("scid", Arrays.asList(targets), Arrays.asList(selectors));
	ScreenshotArgument newObj = arg.withScreenshotId("id");
	// Not same object
	// Only screenshotId is changed
	assertThat(newObj, is(not(sameInstance(arg))));
	assertThat(newObj.getScreenshotId(), is("id"));
	assertArrayEquals(targets, newObj.getTargets().toArray());
	assertArrayEquals(selectors, newObj.getHiddenElementSelectors().toArray());
}