We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 19e8386 commit 996579fCopy full SHA for 996579f
convertapi/format_detector.py
@@ -10,4 +10,4 @@ def detect(resource):
10
else:
11
path = utils.urlparse(resource).path
12
13
- return splitext(path)[1][1:].lower()
+ return splitext(path)[1][1:].lower()
tests/test_convertapi.py
@@ -27,7 +27,7 @@ def test_convert_url(self):
27
assert result.conversion_cost > 0
28
29
def test_upload_io(self):
30
- string_io = io.StringIO(u'test')
31
- upload_io = convertapi.UploadIO(string_io, 'test.txt')
+ bytes_io = io.BytesIO(b'test')
+ upload_io = convertapi.UploadIO(bytes_io, 'test.txt')
32
result = convertapi.convert('pdf', { 'File': upload_io })
33
- assert result.conversion_cost > 0
+ assert result.conversion_cost > 0
0 commit comments