Screen extends AbstractScreen { @Override void setParams() { super.setParams(); tracker.setParam(Hit.HitParam.Screen.stringValue(), completeLabel, new ParamOption().setRelativePosition(ParamOption.RelativePosition.after) .setRelativeParameterKey(Hit.HitParam.UserId.stringValue()) .setEncode(true)); } Screen(Tracker tracker); Screen setName(String name); Screen setAction(Action action); Screen setChapter1(String chapter1); Screen setChapter2(String chapter2); Screen setChapter3(String chapter3); Screen setLevel2(int level2); Screen setLevel2(String level2); Screen setIsBasketScreen(boolean isBasketScreen); String getCompleteLabel();  }
@Test public void setParamsTest() { screen.setName("name").setChapter3("chapter3").setParams(); assertEquals(1, buffer.getVolatileParams().size()); assertEquals(0, buffer.getPersistentParams().size()); assertEquals(1, buffer.getVolatileParams().get("p").getValues().size()); assertEquals("chapter3::name", buffer.getVolatileParams().get("p").getValues().get(0).execute()); }