run: introduce --always-changed

This is an extension of our callback stages (no deps, so always
considered as changed) for stages with dependencies, so that these
stages could be used properly in the middle of the DAG. See attached
issue for more info.

Related to #2378
This commit is contained in:
Ruslan Kuprieiev
2019-09-09 18:03:28 +03:00
parent b3e4ff7cba
commit 357ce82f28
4 changed files with 31 additions and 1 deletions
+4
View File
@@ -32,6 +32,7 @@ def test_run(mocker, dvc_repo):
"outs-persist",
"--outs-persist-no-cache",
"outs-persist-no-cache",
"--always-changed",
"command",
]
)
@@ -58,6 +59,7 @@ def test_run(mocker, dvc_repo):
ignore_build_cache=True,
remove_outs=True,
no_commit=True,
always_changed=True,
cmd="command",
)
@@ -83,6 +85,7 @@ def test_run_args_from_cli(mocker, dvc_repo):
ignore_build_cache=False,
remove_outs=False,
no_commit=False,
always_changed=False,
cmd="echo foo",
)
@@ -108,5 +111,6 @@ def test_run_args_with_spaces(mocker, dvc_repo):
ignore_build_cache=False,
remove_outs=False,
no_commit=False,
always_changed=False,
cmd='echo "foo bar"',
)