aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/testsuite')
-rw-r--r--gdb/testsuite/ChangeLog5
-rw-r--r--gdb/testsuite/gdb.base/style.exp4
-rw-r--r--gdb/testsuite/lib/gdb-utils.exp1
3 files changed, 10 insertions, 0 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index 88cec5d..784daf2 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,5 +1,10 @@
2019-10-01 Tom Tromey <tom@tromey.com>
+ * lib/gdb-utils.exp (style): Handle "metadata" argument.
+ * gdb.base/style.exp: Add metadata style test.
+
+2019-10-01 Tom Tromey <tom@tromey.com>
+
* gdb.base/style.exp: Test "pwd".
2019-10-01 Tom Tromey <tom@tromey.com>
diff --git a/gdb/testsuite/gdb.base/style.exp b/gdb/testsuite/gdb.base/style.exp
index fb0dfed..0f812f7 100644
--- a/gdb/testsuite/gdb.base/style.exp
+++ b/gdb/testsuite/gdb.base/style.exp
@@ -133,4 +133,8 @@ save_vars { env(TERM) } {
"filename is styled when loading symbol file"
gdb_test "pwd" "Working directory [style .*? file].*"
+
+ gdb_test_no_output "set print repeat 3"
+ gdb_test "print {0,0,0,0,0,0,0,0}" \
+ " = \\{0 [style {<repeats.*8.*times>} metadata]\\}"
}
diff --git a/gdb/testsuite/lib/gdb-utils.exp b/gdb/testsuite/lib/gdb-utils.exp
index 89767dc..95ca348 100644
--- a/gdb/testsuite/lib/gdb-utils.exp
+++ b/gdb/testsuite/lib/gdb-utils.exp
@@ -54,6 +54,7 @@ proc style {str style} {
highlight { set style 31 }
variable { set style 36 }
address { set style 34 }
+ metadata { set style 2 }
}
return "\033\\\[${style}m${str}\033\\\[m"
}