-
Notifications
You must be signed in to change notification settings - Fork 425
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1095 from paul23-git/make_recipient_repr_match_imap
Added angled brackets instead of braces to repr of recipient
- Loading branch information
Showing
2 changed files
with
22 additions
and
1 deletion.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import pytest | ||
|
||
from O365.utils import Recipient | ||
|
||
|
||
class TestRecipient: | ||
def setup_class(self): | ||
pass | ||
|
||
def teardown_class(self): | ||
pass | ||
|
||
def test_recipient_str(self): | ||
recipient = Recipient() | ||
assert str(recipient) == "" | ||
|
||
recipient = Recipient(address="john@example.com") | ||
assert str(recipient) == "john@example.com" | ||
|
||
recipient = Recipient(address="john@example.com", name="John Doe") | ||
assert str(recipient) == "John Doe <john@example.com>" |