/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/tests/test__chk_map.py

  • Committer: Breezy landing bot
  • Author(s): Jelmer Vernooij
  • Date: 2020-02-14 03:16:54 UTC
  • mfrom: (7479.2.3 no-more-python2)
  • Revision ID: breezy.the.bot@gmail.com-20200214031654-bp1xtv2jr9nmhto3
Drop python2 support.

Merged from https://code.launchpad.net/~jelmer/brz/no-more-python2/+merge/378694

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
from ..bzr import (
23
23
    chk_map,
24
24
    )
25
 
from ..sixish import int2byte
26
25
from ..static_tuple import StaticTuple
27
26
stuple = StaticTuple
28
27
 
65
64
        chars_used = set()
66
65
        for char_in in range(256):
67
66
            search_key = self.module._search_key_255(
68
 
                stuple(int2byte(char_in),))
69
 
            chars_used.update(map(int2byte, bytearray(search_key)))
70
 
        all_chars = {int2byte(x) for x in range(256)}
 
67
                stuple(bytes([char_in]),))
 
68
            chars_used.update([bytes([x]) for x in search_key])
 
69
        all_chars = {bytes([x]) for x in range(256)}
71
70
        unused_chars = all_chars.symmetric_difference(chars_used)
72
71
        self.assertEqual({b'\n'}, unused_chars)
73
72