tests: lockfile: use different way of changing a cmd

This commit is contained in:
Ruslan Kuprieiev
2023-05-05 04:16:58 +03:00
parent a251cffdb5
commit b044bcce5e
+3 -1
View File
@@ -95,7 +95,9 @@ def test_cmd_changes_other_orders_are_preserved(tmp_dir, dvc, run_head):
# let's change cmd in pipeline file
# it should only change "cmd", otherwise it should be
# structurally same as cmd
stage.cmd = " ".join(stage.cmd.split())
new_cmd = "python head.py foo bar foobar"
assert stage.cmd != new_cmd # sanity check
stage.cmd = new_cmd
stage.dvcfile._dump_pipeline_file(stage)
initial_content["stages"]["copy-first-line"]["cmd"] = stage.cmd