[PATCH] osmo-ttcn3-hacks[master]: add mask_expected_results.sh

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 Hofmeyr gerrit-no-reply at lists.osmocom.org
Wed Apr 11 17:33:34 UTC 2018


Hello Harald Welte, Jenkins Builder,

I'd like you to reexamine a change.  Please visit

    https://gerrit.osmocom.org/7752

to look at the new patch set (#2).

add mask_expected_results.sh

Provide a script to mask timestamps and source file lines in expected results
files: when updating expected changes, it is useful to see the exact semantic
changes, not the timestamp and source file line changes in the git diff.

Change-Id: I785e126b1f5afddd1b722bc5e922ed90970efa8a
---
A mask_expected_results.sh
1 file changed, 7 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/52/7752/2

diff --git a/mask_expected_results.sh b/mask_expected_results.sh
new file mode 100755
index 0000000..f679194
--- /dev/null
+++ b/mask_expected_results.sh
@@ -0,0 +1,7 @@
+#!/bin/sh
+# to prevent diffs due to timing and source file lines, mask some numbers
+
+for target in */expected-results.xml; do
+  sed -i "s/time='[^']*'/time='MASKED'/g" "$target"
+  sed -i 's/ttcn:[0-9]\+/ttcn:MASKED/g' "$target"
+done

-- 
To view, visit https://gerrit.osmocom.org/7752
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I785e126b1f5afddd1b722bc5e922ed90970efa8a
Gerrit-PatchSet: 2
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder



More information about the gerrit-log mailing list