Mercurial > dive4elements > river
diff gwt-client/src/test/java/test/AbstractModuleRunner.java @ 9440:e991c4cec0d0
Backed out changeset: ce0a48b93f4b
author | gernotbelger |
---|---|
date | Mon, 20 Aug 2018 16:58:23 +0200 |
parents | ce0a48b93f4b |
children | e75afd693f78 |
line wrap: on
line diff
--- a/gwt-client/src/test/java/test/AbstractModuleRunner.java Mon Aug 20 16:57:25 2018 +0200 +++ b/gwt-client/src/test/java/test/AbstractModuleRunner.java Mon Aug 20 16:58:23 2018 +0200 @@ -318,15 +318,13 @@ protected final void makeKmRange(final double from, final double to, final String from_key, final String to_key) throws ConnectionException, ServerException { - feedAndGo(makeFromToData(from_key, to_key), 0); - } - - protected final Data[] makeFromToData(final String from_key, final String to_key) { - final String fromStr = String.valueOf(this.from); - final String toStr = String.valueOf(this.to); + final String fromStr = String.valueOf(from); + final String toStr = String.valueOf(to); final Data dataFrom = new StringOptionsData(from_key, from_key, new DataItem[] { new DefaultDataItem(fromStr, fromStr, fromStr) }); final Data dataTo = new StringOptionsData(to_key, to_key, new DataItem[] { new DefaultDataItem(toStr, toStr, toStr) }); - return new Data[] { dataFrom, dataTo }; + final Data[] rangeFromToDetermined = new Data[] { dataFrom, dataTo }; + + feedAndGo(rangeFromToDetermined, 0); } protected final void selectRiver() throws ConnectionException, ServerException { @@ -356,25 +354,9 @@ return rec1.getRecommendationPairString(rec2, getCollection(), this.serverUrl, this.locale); } - protected final void feedAndGoData(final Data[] data) throws ConnectionException, ServerException { - feedAndGo(data, 0); - } - - protected final void feedAndGoSimpleTextInput(final String key, final String value) throws ConnectionException, ServerException { - feedAndGo(new Data[] { getSimpleTextInput(key, value) }, 0); - } - - protected Data getSimpleTextInput(final String key, final String value) throws ConnectionException, ServerException { - return new StringOptionsData(key, key, new DataItem[] { new DefaultDataItem(value, value, value) }); - } - - protected final Data[] addItemToExistingData(final Data[] existing, final Data add) { - final Data[] data = new Data[existing.length + 1]; - for (int i = 0; i < existing.length; i++) { - data[i] = existing[i]; - } - data[existing.length] = add; - return data; + protected final void feedSimpleTextInput(final String key, final String value) throws ConnectionException, ServerException { + final Data data = new StringOptionsData(key, key, new DataItem[] { new DefaultDataItem(value, value, value) }); + feedAndGo(new Data[] { data }, 0); } } \ No newline at end of file