Remove registration_response from webauthn serialize - not needed in admin app

Also fix tests:

First add init file so the tests are found correctly, then update
the tests after we stopped serialising webauthn
registration_response.
This commit is contained in:
Pea Tyczynska
2021-05-11 12:19:33 +01:00
committed by Leo Hemsted
parent e62e050963
commit e6291187ba
3 changed files with 0 additions and 2 deletions

View File

@@ -2622,7 +2622,6 @@ class WebauthnCredential(db.Model):
'user_id': str(self.user_id), 'user_id': str(self.user_id),
'name': self.name, 'name': self.name,
'credential_data': self.credential_data, 'credential_data': self.credential_data,
'registration_response': self.registration_response,
'created_at': self.created_at.strftime(DATETIME_FORMAT), 'created_at': self.created_at.strftime(DATETIME_FORMAT),
'updated_at': get_dt_string_or_none(self.updated_at), 'updated_at': get_dt_string_or_none(self.updated_at),
} }

View File

View File

@@ -24,7 +24,6 @@ def test_get_webauthn_credentials_returns_all_credentials_for_user(admin_request
'user_id': str(me.id), 'user_id': str(me.id),
'name': '1', 'name': '1',
'credential_data': 'ABC123', 'credential_data': 'ABC123',
'registration_response': 'DEF456',
'created_at': ANY, 'created_at': ANY,
'updated_at': None 'updated_at': None
} }