File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -127,16 +127,15 @@ def test_send_photo_url_jpg_file(self):
127
127
@flaky (3 , 1 )
128
128
@timeout (10 )
129
129
def test_send_photo_bytesio_jpg_file (self ):
130
- from telegram .inputfile import InputFile
131
130
# raw image bytes
132
131
raw_bytes = BytesIO (open (self .photo_bytes_jpg_no_standard , 'rb' ).read ())
133
- inputfile = InputFile ({"photo" : raw_bytes })
132
+ inputfile = telegram . InputFile ({"photo" : raw_bytes })
134
133
self .assertEqual (inputfile .mimetype , 'application/octet-stream' )
135
134
136
135
# raw image bytes with name info
137
136
raw_bytes = BytesIO (open (self .photo_bytes_jpg_no_standard , 'rb' ).read ())
138
137
raw_bytes .name = self .photo_bytes_jpg_no_standard
139
- inputfile = InputFile ({"photo" : raw_bytes })
138
+ inputfile = telegram . InputFile ({"photo" : raw_bytes })
140
139
self .assertEqual (inputfile .mimetype , 'image/jpeg' )
141
140
142
141
# send raw photo
You can’t perform that action at this time.
0 commit comments