def test_rrname_compressed(): rr = RRNAME.parse( '\xc0\x02' # ptr to absolute offset 2 '\x05hello' # rr name '\x00' # end of rr name ) assert rr.name == ['hello', '']
def test_rrname(): rr = RRNAME.parse( '\x05hello' # rr name '\x00' # end of rr name ) assert rr.name == ['hello', '']