Skip to content
Merged
Prev Previous commit
Next Next commit
[LIB-660] add binary mode to read file
  • Loading branch information
opalczynski committed Apr 21, 2016
commit 670087186c8b500b447e9f20f5652b4d3ac68612
2 changes: 1 addition & 1 deletion syncano/connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ def get_user_info(self, api_key=None, user_key=None):

def _process_apns_cert_files(self, files):
files = files.copy()
for key in files.keys():
for key in [file_name for file_name in files.keys()]:
# remove certificates files (which are bool - True if cert exist, False otherwise)
value = files[key]
if isinstance(value, bool):
Expand Down
2 changes: 1 addition & 1 deletion tests/integration_test_push.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def setUpClass(cls):
)
cls.gcm_config.save()

with open('tests/certificates/ApplePushDevelopment.p12', 'r') as cert:
with open('tests/certificates/ApplePushDevelopment.p12', 'rb') as cert:
cls.apns_config = APNSConfig(
development_certificate=cert,
development_certificate_name='test',
Expand Down