ceph plugin: Really fix "parse_keys" test.
authorFlorian Forster <octo@collectd.org>
Tue, 9 Aug 2016 08:14:03 +0000 (10:14 +0200)
committerFlorian Forster <octo@collectd.org>
Tue, 9 Aug 2016 08:18:41 +0000 (10:18 +0200)
This reverts commit 9521a596cb88b044a2f08db53520edd6e15c8d39.

src/ceph_test.c

index 59d1b4e..91f084f 100644 (file)
@@ -154,12 +154,12 @@ DEF_TEST(parse_keys)
     const char *str;
     const char *want;
   } cases[] = {
-    {"WBThrottle.bytes_dirtied.description.bytes_wb.description.ios_dirtied.description.ios_wb.type", "WBThrottle.bytesDirtied.description.bytesWb.description.iosDirtied.description.iosWb"},
-    {"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa:bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb", "AaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaBbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb"},
+    {"WBThrottle.bytes_dirtied.description.bytes_wb.description.ios_dirtied.description.ios_wb.type", "WBThrottle.bytesDirtied.description.bytesWb.description.iosDirt"},
+    {"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa:bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb", "Aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"},
     {"foo:bar", "FooBar"},
     {"foo:bar+", "FooBarPlus"},
     {"foo:bar-", "FooBarMinus"},
-    {"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa+", "AaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaPlus"},
+    {"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa+", "AaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaPlus"},
     {"aa.bb.cc.dd.ee.ff", "Aa.bb.cc.dd.ee.ff"},
     {"aa.bb.cc.dd.ee.ff.type", "Aa.bb.cc.dd.ee.ff"},
     {"aa.type", "Aa.type"},
@@ -169,7 +169,7 @@ DEF_TEST(parse_keys)
 
   for (i = 0; i < STATIC_ARRAY_SIZE (cases); i++)
   {
-    char got[DATA_MAX_NAME_LEN];
+    char got[64];
 
     CHECK_ZERO (parse_keys (got, sizeof (got), cases[i].str));
     EXPECT_EQ_STR (cases[i].want, got);