aboutsummaryrefslogtreecommitdiff
path: root/src/statistics
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2014-02-11 12:33:51 +0000
committerChristian Grothoff <christian@grothoff.org>2014-02-11 12:33:51 +0000
commit10bc3b99a7d8a19d8a924e93da842c1aba40cfe4 (patch)
treed80ba399a2140c7271df99f5b0255ed8a7792fdc /src/statistics
parent7daab7b7f8478178fe230a816ac590e4f46fc83a (diff)
downloadgnunet-10bc3b99a7d8a19d8a924e93da842c1aba40cfe4.tar.gz
gnunet-10bc3b99a7d8a19d8a924e93da842c1aba40cfe4.zip
trying to fix #3281
Diffstat (limited to 'src/statistics')
-rw-r--r--src/statistics/test_gnunet_statistics.py.in16
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
86print ("PASS") 86print ("PASS")
87 87
88print ("TEST: Set value...", end='') 88print ("TEST: Set value...", end='')
89r_st (['-n', 'test', '-s', 'subsystem', '42'], nofail = True, want_stdo = False) 89r_st (['-n', 'test', '-s', 'subsystem', b'42'], nofail = True, want_stdo = False)
90print ("PASS") 90print ("PASS")
91 91
92print ("TEST: Set another value...", end='') 92print ("TEST: Set another value...", end='')
93r_st (['-n', 'other', '-s', 'osystem', '43'], nofail = True, want_stdo = False) 93r_st (['-n', 'other', '-s', 'osystem', b'43'], nofail = True, want_stdo = False)
94print ("PASS") 94print ("PASS")
95 95
96print ("TEST: Viewing all stats...", end='') 96print ("TEST: Viewing all stats...", end='')
@@ -101,20 +101,20 @@ print ("PASS")
101 101
102print ("TEST: Viewing stats by name...", end='') 102print ("TEST: Viewing stats by name...", end='')
103rc, stdo, stde = r_st (['-n', 'other'], nofail = True, want_stdo = True) 103rc, stdo, stde = r_st (['-n', 'other'], nofail = True, want_stdo = True)
104if len ([x for x in stdo.splitlines () if re.search ('43', x)]) != 1: 104if 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))
106print ("PASS") 106print ("PASS")
107 107
108print ("TEST: Viewing stats by subsystem...", end='') 108print ("TEST: Viewing stats by subsystem...", end='')
109rc, stdo, stde = r_st (['-s', 'subsystem'], nofail = True, want_stdo = True) 109rc, stdo, stde = r_st (['-s', 'subsystem'], nofail = True, want_stdo = True)
110if len ([x for x in stdo.splitlines () if re.search ('42', x)]) != 1: 110if 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))
112print ("PASS") 112print ("PASS")
113 113
114print ("TEST: Set persistent value...", end='') 114print ("TEST: Set persistent value...", end='')
115rc, stdo, stde = r_st (['-n', 'lasting', '-s', 'subsystem', '40', '-p'], nofail = True, want_stdo = False) 115rc, stdo, stde = r_st (['-n', 'lasting', '-s', 'subsystem', '40', '-p'], nofail = True, want_stdo = False)
116rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) 116rc, stdo, stde = r_st ([], nofail = True, want_stdo = True)
117if len ([x for x in stdo.splitlines () if re.search ('40', x)]) != 1: 117if 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))
119print ("PASS") 119print ("PASS")
120 120
@@ -122,14 +122,14 @@ restart ()
122 122
123print ("TEST: Checking persistence...", end='') 123print ("TEST: Checking persistence...", end='')
124rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) 124rc, stdo, stde = r_st ([], nofail = True, want_stdo = True)
125if len ([x for x in stdo.splitlines () if re.search ('40', x)]) != 1: 125if 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))
127print ("PASS") 127print ("PASS")
128 128
129print ("TEST: Removing persistence...", end='') 129print ("TEST: Removing persistence...", end='')
130rc, stdo, stde = r_st (['-n', 'lasting', '-s', 'subsystem', '40'], nofail = True, want_stdo = False) 130rc, stdo, stde = r_st (['-n', 'lasting', '-s', 'subsystem', '40'], nofail = True, want_stdo = False)
131rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) 131rc, stdo, stde = r_st ([], nofail = True, want_stdo = True)
132if len ([x for x in stdo.splitlines () if re.search ('!', x)]) != 0: 132if 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))
134print ("PASS") 134print ("PASS")
135 135
@@ -137,7 +137,7 @@ restart ()
137 137
138print ("TEST: Checking removed persistence...", end='') 138print ("TEST: Checking removed persistence...", end='')
139rc, stdo, stde = r_st ([], nofail = True, want_stdo = True) 139rc, stdo, stde = r_st ([], nofail = True, want_stdo = True)
140if len ([x for x in stdo.splitlines () if re.search ('40', x)]) != 0: 140if 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))
142print ("PASS") 142print ("PASS")
143 143