-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ref: don't guess about str / bytes in tests (#53366)
force_str / force_bytes really should not be used -- these are the easy ones to fix <!-- Describe your PR here. -->
- Loading branch information
1 parent
446ea57
commit 91f9f3c
Showing
5 changed files
with
17 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
import pytest | ||
from django.urls import reverse | ||
from django.utils.encoding import force_bytes | ||
|
||
from sentry import identity | ||
from sentry.identity.providers.dummy import DummyProvider | ||
|
@@ -35,7 +34,7 @@ def test_associate_identity(self): | |
resp = self.client.post(path) | ||
|
||
assert resp.status_code == 200 | ||
assert resp.content == force_bytes(DummyProvider.TEMPLATE) | ||
assert resp.content == DummyProvider.TEMPLATE.encode() | ||
|
||
resp = self.client.post(path, data={"email": "[email protected]"}) | ||
ident = Identity.objects.get(user=user) | ||
|