diff options
author | Christian Grothoff <christian@grothoff.org> | 2014-02-11 12:33:51 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2014-02-11 12:33:51 +0000 |
commit | 10bc3b99a7d8a19d8a924e93da842c1aba40cfe4 (patch) | |
tree | d80ba399a2140c7271df99f5b0255ed8a7792fdc /src/statistics | |
parent | 7daab7b7f8478178fe230a816ac590e4f46fc83a (diff) | |
download | gnunet-10bc3b99a7d8a19d8a924e93da842c1aba40cfe4.tar.gz gnunet-10bc3b99a7d8a19d8a924e93da842c1aba40cfe4.zip |
trying to fix #3281
Diffstat (limited to 'src/statistics')
-rw-r--r-- | src/statistics/test_gnunet_statistics.py.in | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/statistics/test_gnunet_statistics.py.in b/src/statistics/test_gnunet_statistics.py.in index a7785ba1f..86d0258f4 100644 --- a/src/statistics/test_gnunet_statistics.py.in +++ b/src/statistics/test_gnunet_statistics.py.in | |||
@@ -86,11 +86,11 @@ r_st (['-x'], normal = False, nofail = True, want_stdo = False, want_stde = True | |||
86 | print ("PASS") | 86 | print ("PASS") |
87 | 87 | ||
88 | print ("TEST: Set value...", end='') | 88 | print ("TEST: Set value...", end='') |
89 | r_st (['-n', 'test', '-s', 'subsystem', '42'], nofail = True, want_stdo = False) | 89 | r_st (['-n', 'test', '-s', 'subsystem', b'42'], nofail = True, want_stdo = False) |
90 | print ("PASS") | 90 | print ("PASS") |
91 | 91 | ||
92 | print ("TEST: Set another value...", end='') | 92 | print ("TEST: Set another value...", end='') |
93 | r_st (['-n', 'other', '-s', 'osystem', '43'], nofail = True, want_stdo = False) | 93 | r_st (['-n', 'other', '-s', 'osystem', b'43'], nofail = True, want_stdo = False) |
94 | print ("PASS") | 94 | print ("PASS") |
95 | 95 | ||
96 | print ("TEST: Viewing all stats...", end='') | 96 | print ("TEST: Viewing all stats...", end='') |
@@ -101,20 +101,20 @@ print ("PASS") | |||
101 | 101 | ||
102 | print ("TEST: Viewing stats by name...", end='') | 102 | print ("TEST: Viewing stats by name...", end='') |
103 | rc, stdo, stde = r_st (['-n', 'other'], nofail = True, want_stdo = True) | 103 | rc, stdo, stde = r_st (['-n', 'other'], nofail = True, want_stdo = True) |
104 | if len ([x for x in stdo.splitlines () if re.search ('43', x)]) != 1: | 104 | if len ([x for x in stdo.splitlines () if re.search (b'43', x)]) != 1: |
105 | fail ("FAIL: unexpected output:\n{}".format (stdo)) | 105 | fail ("FAIL: unexpected output:\n{}".format (stdo)) |
106 | print ("PASS") | 106 | print ("PASS") |
107 | 107 | ||
108 | print ("TEST: Viewing stats by subsystem...", end='') | 108 | print ("TEST: Viewing stats by subsystem...", end='') |
109 | rc, stdo, stde = r_st (['-s', 'subsystem'], nofail = True, want_stdo = True) | 109 | rc, stdo, stde = r_st (['-s', 'subsystem'], nofail = True, want_stdo = True) |
110 | if len ([x for x in stdo.splitlines () if re.search ('42', x)]) != 1: | 110 | if len ([x for x in stdo.splitlines () if re.search (b'42', x)]) != 1: |
111 | fail ("FAIL: unexpected output:\n{}".format (stdo)) | 111 | fail ("FAIL: unexpected output:\n{}".format (stdo)) |
112 | print ("PASS") | 112 | print ("PASS") |
113 | 113 | ||
114 | print ("TEST: Set persistent value...", end='') | 114 | print ("TEST: Set persistent value...", end='') |
115 | rc, stdo, stde = r_st (['-n', 'lasting', '-s', 'subsystem', '40', '-p'], nofail = True, want_stdo = False) | 115 | rc, stdo, stde = r_st (['-n', 'lasting', '-s', 'subsystem', '40', '-p'], nofail = True, want_stdo = False) |
116 | rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) | 116 | rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) |
117 | if len ([x for x in stdo.splitlines () if re.search ('40', x)]) != 1: | 117 | if len ([x for x in stdo.splitlines () if re.search (b'40', x)]) != 1: |
118 | fail ("FAIL: unexpected output:\n{}".format (stdo)) | 118 | fail ("FAIL: unexpected output:\n{}".format (stdo)) |
119 | print ("PASS") | 119 | print ("PASS") |
120 | 120 | ||
@@ -122,14 +122,14 @@ restart () | |||
122 | 122 | ||
123 | print ("TEST: Checking persistence...", end='') | 123 | print ("TEST: Checking persistence...", end='') |
124 | rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) | 124 | rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) |
125 | if len ([x for x in stdo.splitlines () if re.search ('40', x)]) != 1: | 125 | if len ([x for x in stdo.splitlines () if re.search (b'40', x)]) != 1: |
126 | fail ("FAIL: unexpected output:\n{}".format (stdo)) | 126 | fail ("FAIL: unexpected output:\n{}".format (stdo)) |
127 | print ("PASS") | 127 | print ("PASS") |
128 | 128 | ||
129 | print ("TEST: Removing persistence...", end='') | 129 | print ("TEST: Removing persistence...", end='') |
130 | rc, stdo, stde = r_st (['-n', 'lasting', '-s', 'subsystem', '40'], nofail = True, want_stdo = False) | 130 | rc, stdo, stde = r_st (['-n', 'lasting', '-s', 'subsystem', '40'], nofail = True, want_stdo = False) |
131 | rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) | 131 | rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) |
132 | if len ([x for x in stdo.splitlines () if re.search ('!', x)]) != 0: | 132 | if len ([x for x in stdo.splitlines () if re.search (b'!', x)]) != 0: |
133 | fail ("FAIL: unexpected output:\n{}".format (stdo)) | 133 | fail ("FAIL: unexpected output:\n{}".format (stdo)) |
134 | print ("PASS") | 134 | print ("PASS") |
135 | 135 | ||
@@ -137,7 +137,7 @@ restart () | |||
137 | 137 | ||
138 | print ("TEST: Checking removed persistence...", end='') | 138 | print ("TEST: Checking removed persistence...", end='') |
139 | rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) | 139 | rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) |
140 | if len ([x for x in stdo.splitlines () if re.search ('40', x)]) != 0: | 140 | if len ([x for x in stdo.splitlines () if re.search (b'40', x)]) != 0: |
141 | fail ("FAIL: unexpected output:\n{}".format (stdo)) | 141 | fail ("FAIL: unexpected output:\n{}".format (stdo)) |
142 | print ("PASS") | 142 | print ("PASS") |
143 | 143 | ||