I have some file with bytes inside:
b'<html lang="en" class="wf-roboto-n4-active wf-roboto-n3-active wf-poppins-n7-active wf-poppins-n4-active wf-poppins-n3-active wf-roboto-n7-active wf-roboto-n5-active wf-sourcecodepro-n5-active wf-poppins-n5-active wf-poppins-n6-active wf-active"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1">'
And i try to read this file inside unit tetst in 'rb' mode:
def test_04_foo(self):
with open('test_data.txt', 'rb') as reader:
print(reader.read())
#some code here
And i have b'' in stdout.
How i can get bytes from file?