Skip to content

Commit

Permalink
Use loop for clarity
Browse files Browse the repository at this point in the history
  • Loading branch information
danielmitterdorfer committed Feb 3, 2020
1 parent c0b5772 commit 51c0df6
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions tests/mechanic/launcher_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,11 @@ def test_daemon_start_stop(self, wait_for_pidfile, chdir, get_size, supports, ja
ms = get_metrics_store(cfg)
proc_launcher = launcher.ProcessLauncher(cfg)

node_configs = [NodeConfiguration(build_type="tar", car_env={}, car_runtime_jdks="12,11", ip="127.0.0.1",
node_name="testnode-{}".format(n), node_root_path="/tmp", binary_path="/tmp",
data_paths="/tmp") for n in range(2)]
node_configs = []
for node in range(2):
node_configs.append(NodeConfiguration(build_type="tar", car_env={}, car_runtime_jdks="12,11",
ip="127.0.0.1", node_name="testnode-{}".format(node),
node_root_path="/tmp", binary_path="/tmp", data_paths="/tmp"))

nodes = proc_launcher.start(node_configs)
self.assertEqual(len(nodes), 2)
Expand Down

0 comments on commit 51c0df6

Please sign in to comment.