use of org.neo4j.shell.state.ParamValue in project neo4j by neo4j.
the class ParamsTest method runCommandWithArgWithExtraSpace.
@Test
public void runCommandWithArgWithExtraSpace() throws CommandException {
// given
vars.put("var", new ParamValue(String.valueOf(9), 9));
vars.put("param", new ParamValue(String.valueOf(9999), 9999));
// when
cmd.execute(" var");
// then
verify(logger).printOut(":param var => 9");
verifyNoMoreInteractions(logger);
}
use of org.neo4j.shell.state.ParamValue in project neo4j by neo4j.
the class ParamsTest method runCommandAlignment.
@Test
public void runCommandAlignment() throws CommandException {
// given
vars.put("var", new ParamValue(String.valueOf(9), 9));
vars.put("param", new ParamValue(String.valueOf(99999), 99999));
// when
cmd.execute("");
// then
verify(logger).printOut(":param param => 99999");
verify(logger).printOut(":param var => 9");
verifyNoMoreInteractions(logger);
}
use of org.neo4j.shell.state.ParamValue in project neo4j by neo4j.
the class ParamsTest method runCommand.
@Test
public void runCommand() throws CommandException {
// given
String var = "var";
int value = 9;
vars.put(var, new ParamValue(String.valueOf(value), value));
// when
cmd.execute("");
// then
verify(logger).printOut(":param var => 9");
verifyNoMoreInteractions(logger);
}
use of org.neo4j.shell.state.ParamValue in project neo4j by neo4j.
the class ParamsTest method runCommandWithArgWithBackticks.
@Test
public void runCommandWithArgWithBackticks() throws CommandException {
// given
vars.put("var", new ParamValue(String.valueOf(9), 9));
vars.put("param", new ParamValue(String.valueOf(9999), 9999));
// when
cmd.execute("`var`");
// then
verify(logger).printOut(":param `var` => 9");
verifyNoMoreInteractions(logger);
}
Aggregations