diff options
| author | Damian Johnson <atagar@torproject.org> | 2019-05-24 11:46:43 -0700 |
|---|---|---|
| committer | Damian Johnson <atagar@torproject.org> | 2019-05-24 11:46:43 -0700 |
| commit | f5093b2ed67bcdad8d51d83db780c09bf142f57c (patch) | |
| tree | 0b96959606a1784c52ce26ea3617f74123456eca | |
| parent | eabc0811b021f62170ceed6853ef2c602343c84b (diff) | |
Fix test_version_position for python3
Correcting a couple typing regressions that slipped in...
https://trac.torproject.org/projects/tor/ticket/30597
| -rw-r--r-- | stem/descriptor/bandwidth_file.py | 2 | ||||
| -rw-r--r-- | test/unit/descriptor/bandwidth_file.py | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/stem/descriptor/bandwidth_file.py b/stem/descriptor/bandwidth_file.py index a26b2d57..1f000f50 100644 --- a/stem/descriptor/bandwidth_file.py +++ b/stem/descriptor/bandwidth_file.py @@ -104,7 +104,7 @@ def _date(val): def _csv(val): - return map(lambda v: v.strip(), val.split(',')) if val is not None else None + return list(map(lambda v: v.strip(), val.split(','))) if val is not None else None # mapping of attributes => (header, type) diff --git a/test/unit/descriptor/bandwidth_file.py b/test/unit/descriptor/bandwidth_file.py index 8cb0b942..3040c38b 100644 --- a/test/unit/descriptor/bandwidth_file.py +++ b/test/unit/descriptor/bandwidth_file.py @@ -85,14 +85,14 @@ new_header=neat stuff ===== """.strip() -WRONG_VERSION_POSITION = """ +WRONG_VERSION_POSITION = b""" 1410723598 file_created=2019-01-14T05:35:06 version=1.1.0 ===== """.strip() -RIGHT_VERSION_POSITION = """ +RIGHT_VERSION_POSITION = b""" 1410723598 version=1.1.0 file_created=2019-01-14T05:35:06 |
