Change in osmo-bsc[master]: handover_tests.sh: update stdout/stderr only on capital -U arg

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

neels gerrit-no-reply at lists.osmocom.org
Sun Jan 17 19:53:00 UTC 2021


neels has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bsc/+/22260 )


Change subject: handover_tests.sh: update stdout/stderr only on capital -U arg
......................................................................

handover_tests.sh: update stdout/stderr only on capital -U arg

On -u, update the handover_tests.ok file that lists all tests that are
expected to run. This is necessary for the regression tests to succeed.

Update all the numerous test_*.ho_vty.{err,ok} files only when the
update arg is a captial -U, because those are usually not interesting,
except for manual comparison of test runs.

Change-Id: Id280a8d084fd84b0b7486a5c8022e5b7a26f6095
---
M tests/handover/handover_tests.sh
1 file changed, 3 insertions(+), 3 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/60/22260/1

diff --git a/tests/handover/handover_tests.sh b/tests/handover/handover_tests.sh
index 240b789..4be0c10 100755
--- a/tests/handover/handover_tests.sh
+++ b/tests/handover/handover_tests.sh
@@ -6,7 +6,7 @@
 test -d "$tests_dir"
 test -d "$build_dir"
 
-if [ -n "$update" -a "x$update" != "x-u" ]; then
+if [ -n "$update" -a "x$update" != "x-u" -a "x$update" != "x-U" ]; then
 	echo "unknown argument: $update"
 	exit 1
 fi
@@ -21,7 +21,7 @@
 	rc=$?
 	expect_out="$test_path.ok"
 	expect_err="$test_path.err"
-	if [ "x$rc" = "x0" -a  "x$update" = "x-u" ]; then
+	if [ "x$rc" = "x0" -a  "x$update" = "x-U" ]; then
 		cp "$got_out" "$expect_out"
 		cp "$got_err" "$expect_err"
 	else
@@ -50,7 +50,7 @@
 set +e
 cat "$results"
 failed="$(grep FAIL "$results")"
-if [ -z "$failed" -a "x$update" = "x-u" ]; then
+if [ -z "$failed" -a "x$update" != "x" ]; then
 	cp "$results" "$tests_dir"/handover_tests.ok
 fi
 rm "$results"

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/22260
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: Id280a8d084fd84b0b7486a5c8022e5b7a26f6095
Gerrit-Change-Number: 22260
Gerrit-PatchSet: 1
Gerrit-Owner: neels <nhofmeyr at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210117/46956c54/attachment.htm>


More information about the gerrit-log mailing list