summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2014-03-27 20:23:38 +0000
committerLars Wirzenius <liw@liw.fi>2014-03-27 20:23:38 +0000
commited1c176dd2b45f7f3255d2bbfd1deeda5912c355 (patch)
tree51fb71cd6a12d3524ae2cc558617481b5e31b193
parentba573bae800e2f4950c01f517eeeb5fe05f78e19 (diff)
downloadcmdtest-ed1c176dd2b45f7f3255d2bbfd1deeda5912c355.tar.gz
Stop yarn from failing test if snapshot fails
-rw-r--r--NEWS7
-rwxr-xr-xyarn5
2 files changed, 11 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index 335c679..57e12f2 100644
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,13 @@ NEWS for cmdtest
This file summarizes changes between releases of cmdtest.
+Version 0.12, released UNRELEASED
+---------------------------------
+
+For yarn:
+
+* Do not fail a test suite if snapshotting `DATADIR` fails.
+
Version 0.11, released 2014-03-15
---------------------------------
diff --git a/yarn b/yarn
index bb62493..c34ccbb 100755
--- a/yarn
+++ b/yarn
@@ -454,7 +454,10 @@ class YarnRunner(cliapp.Application):
def snapshot_datadir(self, tempdir, datadir, scenario, step_number, step):
snapshot = self.snapshot_dir(tempdir, scenario, step, step_number)
- cliapp.runcmd(['cp', '-ax', datadir, snapshot])
+ exit, out, err = cliapp.runcmd_unchecked(
+ ['cp', '-ax', datadir, snapshot])
+ if exit != 0:
+ logging.warning('Snapshot copy failed:\n%s\n%s' % (out, err))
def nice(self, name):
# Quote a scenario or step name so it forms a nice filename.