[stem/master] Integ test failed when tor versions didn't include a space

commit bc0ba05b8c8d68c2085299e9e8f008ffbf622aa7 Author: Damian Johnson <atagar@torproject.org> Date: Wed Feb 24 09:44:39 2016 -0800 Integ test failed when tor versions didn't include a space Great catch from toralf. When using a tor release rather than the git version test_getinfo_version_parsing fails with... ValueError: '0.2.7.' isn't a properly formatted tor version --- test/integ/version.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/integ/version.py b/test/integ/version.py index 8347b35..7ba8e7a 100644 --- a/test/integ/version.py +++ b/test/integ/version.py @@ -62,5 +62,5 @@ class TestVersion(unittest.TestCase): # 250 OK tor_version = list(version_response)[0] - tor_version = tor_version[8:tor_version.find(' ', 8)] + tor_version = tor_version[8:].split(' ', 1)[0] stem.version.Version(tor_version)
participants (1)
-
atagar@torproject.org