ScriptStepFactory { public static ScriptStep createCookie(String name, String value, String domain, String path) { ScriptStep ret = new ScriptStep(); Set<RequestData> ds = new HashSet<RequestData>(); ret.setData(ds); ret.setType(ScriptConstants.COOKIE); RequestData data = new RequestData(); data.setType(ScriptConstants.COOKIE); data.setKey(ScriptConstants.COOKIE_NAME); data.setValue(name); ds.add(data); data = new RequestData(); data.setType(ScriptConstants.COOKIE); data.setKey(ScriptConstants.COOKIE_VALUE); data.setValue(value); ds.add(data); data = new RequestData(); data.setType(ScriptConstants.COOKIE); data.setKey(ScriptConstants.COOKIE_DOMAIN); data.setValue(domain); ds.add(data); data = new RequestData(); data.setType(ScriptConstants.COOKIE); data.setKey(ScriptConstants.COOKIE_PATH); data.setValue(StringUtils.isNotBlank(path) ? path : "/"); ds.add(data); ret.setComments("Cookie Step: " + name + " = " + value); return ret; }  static ScriptStep createVariable(String key, String value); static ScriptStep createThinkTime(String minTime, String maxTime); static ScriptStep createAuthentication(String userName, String password, String realm, AuthScheme scheme, String host, String port); static ScriptStep createSleepTime(String delay); static ScriptStep createLogic(String name, String script); static ScriptStep createCookie(String name, String value, String domain, String path); static ScriptStep createClearCookies();  }
@Test public void testCreateCookie_1() throws Exception { String name = ""; String value = ""; String domain = ""; String path = ""; ScriptStep result = ScriptStepFactory.createCookie(name, value, domain, path); assertNotNull(result); }
@Test public void testCreateCookie_2() throws Exception { String name = ""; String value = ""; String domain = ""; String path = ""; ScriptStep result = ScriptStepFactory.createCookie(name, value, domain, path); assertNotNull(result); }