Browse Source

Add dump test for max depth option.

Dave Collins 13 years ago
parent
commit
cddf8663bd
1 changed files with 5 additions and 0 deletions
  1. 5 0
      spew/spew_test.go

+ 5 - 0
spew/spew_test.go

@@ -152,6 +152,11 @@ func initSpewTests() {
 		{scsNoPmethods, fCSFprint, "", tps, "test"},
 		{scsNoPmethods, fCSFprint, "", &tps, "<*>stringer test"},
 		{scsMaxDepth, fCSFprint, "", dt, "{{<max>} [<max>] [<max>] map[<max>]}"},
+		{scsMaxDepth, fCSFdump, "", dt, "(spew_test.depthTester) {\n" +
+			" ic: (spew_test.indirCir1) {\n  <max depth reached>\n },\n" +
+			" arr: ([1]string) {\n  <max depth reached>\n },\n" +
+			" slice: ([]string) {\n  <max depth reached>\n },\n" +
+			" m: (map[string]int) {\n  <max depth reached>\n }\n}\n"},
 	}
 }