[DTrace-devel] [PATCH] test: Fix tst.goodkey.d

Kris Van Hees kris.van.hees at oracle.com
Fri Sep 2 03:32:37 UTC 2022


The tests uses vtimestamp which is not implemented yet.  It is valid to
substitute timestamp instead.

The post-processor also needs tweaking because it was not properly
substituting numbers in the output with only a single space between them.

Signed-off-by: Kris Van Hees <kris.van.hees at oracle.com>
---
 test/unittest/aggs/tst.goodkey.d   | 2 +-
 test/unittest/aggs/tst.goodkey.r.p | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/test/unittest/aggs/tst.goodkey.d b/test/unittest/aggs/tst.goodkey.d
index 26f52fad..97ed0847 100644
--- a/test/unittest/aggs/tst.goodkey.d
+++ b/test/unittest/aggs/tst.goodkey.d
@@ -24,7 +24,7 @@ tick-10ms
 /i != 5/
 {
 	i++;
-	@counts[execname, pid, id, tid, arg0, vtimestamp ] = count();
+	@counts[execname, pid, id, tid, arg0, timestamp ] = count();
 
 }
 
diff --git a/test/unittest/aggs/tst.goodkey.r.p b/test/unittest/aggs/tst.goodkey.r.p
index 3093029b..fef02bd8 100755
--- a/test/unittest/aggs/tst.goodkey.r.p
+++ b/test/unittest/aggs/tst.goodkey.r.p
@@ -16,7 +16,7 @@ NF != 7 { exit(1); }
                  }
 
     # we do not care what the other numbers are
-    gsub(/ -?[0-9]+ /, " number ");
+    gsub(/ -?[0-9]+/, " number ");
 
     # ignore the first column (which can be anything)
     # ignore the last column (which we already checked)
-- 
2.34.1




More information about the DTrace-devel mailing list