-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
now extracting tags out of Zendesk (#25)
* now extracting tags out of Zendesk * Update test_zendesk to remove regularly changing thing
- Loading branch information
1 parent
ea0dcb0
commit ee4b612
Showing
3 changed files
with
16 additions
and
2 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -82,7 +82,7 @@ def test_get_user(caplog): | |
assert entry.levelno < logging.ERROR | ||
assert isinstance(user, ZendeskUser) | ||
|
||
assert user.name == "test fg" | ||
assert isinstance(user.name, str) | ||
assert user.email == "[email protected]" | ||
assert user.user_id == 417316391 | ||
assert user.organisationID is None | ||
|
@@ -160,6 +160,18 @@ def test_search_for_tickets(caplog): | |
assert isinstance(ticket, ZendeskTicket) | ||
|
||
|
||
def test_tags_included(caplog): | ||
"Check that the tags are included in the ticket" | ||
|
||
zend = zendesk(ZENDESK_HOST, ZENDESK_KEY) | ||
search_str = "1239674" | ||
|
||
tickets = zend.search_for_tickets(search_string=search_str) | ||
for _, ticket in tickets.items(): | ||
assert isinstance(ticket, ZendeskTicket) | ||
assert len(ticket.tags) > 0 | ||
|
||
|
||
def test_worklog_parse(): | ||
"check that if missing fields aren't supplied, the worklog is not reported as valid" | ||
log = ZendeskWorklog() | ||
|