Fix test failures

This commit is contained in:
Madhavan Sridharan 2024-04-12 16:30:36 -04:00
parent efc82f03f8
commit fa7ffee9bf
2 changed files with 19 additions and 4 deletions

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2022-2023 nosqlbench * Copyright (c) 2022-2024 nosqlbench
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -188,7 +188,7 @@ public class NBCLIScenarioPreprocessorTest {
"tags", "block:\"schema.*\"", "tags", "block:\"schema.*\"",
"workload", "scenario_test" "workload", "scenario_test"
)); ));
NBCLIOptions opts1 = new NBCLIOptions(new String[]{"local/example_scenarios", "namedsteps.one", "testparam1=testvalue2"}, NBCLIOptions.Mode.ParseAllOptions); NBCLIOptions opts1 = new NBCLIOptions(new String[]{"example_scenarios", "namedsteps.one", "testparam1=testvalue2"}, NBCLIOptions.Mode.ParseAllOptions);
List<Cmd> cmds1 = opts1.getCommands(); List<Cmd> cmds1 = opts1.getCommands();
assertThat(cmds1.size()).isEqualTo(1); assertThat(cmds1.size()).isEqualTo(1);
assertThat(cmds1.get(0).getArgValueOrNull("cycles_test")).isNull(); assertThat(cmds1.get(0).getArgValueOrNull("cycles_test")).isNull();

View File

@ -0,0 +1,15 @@
# example-scenarios.yaml
scenarios:
default:
one: run cycles=3 alias=A driver=stdout
two: run cycles=5 alias=B driver=stdout
namedsteps:
one: run cycles=3 alias=A driver=stdout testparam1=testvalue1
two: run cycles=5 alias=B driver=stdout
bindings:
cycle: Identity()
name: NumberNameToCycle()
ops:
cycle: "cycle {cycle}\n"