Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

source-zendesk-support: update ticket_skips schema #1988

Merged
merged 2 commits into from
Sep 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions source-zendesk-support/acmeCo/posts.schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ properties:
type:
- "null"
- number
- string
featured:
type:
- "null"
Expand Down
9 changes: 9 additions & 0 deletions source-zendesk-support/acmeCo/ticket_metrics.schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,15 @@ properties:
type:
- "null"
- integer
reply_time_in_seconds:
type:
- "null"
- object
properties:
calendar:
type:
- "null"
- integer
requester_updated_at:
type:
- "null"
Expand Down
5 changes: 5 additions & 0 deletions source-zendesk-support/acmeCo/ticket_skips.schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,14 @@ properties:
- "null"
- integer
value:
items:
type:
- "null"
- string
type:
- "null"
- string
- array
type:
- "null"
- object
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,16 @@
]
},
"value": {
"items": {
"type": [
"null",
"string"
]
},
"type": [
"null",
"string"
"string",
"array"
]
}
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,17 +75,19 @@
"uuid": "DocUUIDPlaceholder-329Bb50aa48EAa9ef"
},
"created_at": "2024-07-26T15:41:00Z",
"details": null,
"details": "",
"domain_names": [],
"external_id": null,
"group_id": null,
"id": 28835714737428,
"name": "Estuary",
"notes": null,
"notes": "",
"organization_fields": {},
"shared_comments": false,
"shared_tickets": false,
"tags": [],
"tags": [
"test-tag"
],
"updated_at": "redacted",
"url": "https://d3v-estuary.zendesk.com/api/v2/organizations/28835714737428.json"
}
Expand Down Expand Up @@ -301,8 +303,8 @@
"row_id": 0,
"uuid": "DocUUIDPlaceholder-329Bb50aa48EAa9ef"
},
"count": 1,
"name": "assembly"
"name": "redacted",
"count": 1
}
],
[
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3369,9 +3369,16 @@
]
},
"value": {
"items": {
"type": [
"null",
"string"
]
},
"type": [
"null",
"string"
"string",
"array"
]
}
},
Expand Down
9 changes: 8 additions & 1 deletion source-zendesk-support/tests/test_snapshots.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,20 @@ def test_capture(request, snapshot):
seen.add(stream)

for l in unique_stream_lines:
_, rec = l[0], l[1]
stream, rec = l[0], l[1]

rec['_meta']['row_id'] = 0
if "updated_at" in rec:
rec["updated_at"] = "redacted"
if "last_login_at" in rec:
rec["last_login_at"] = "redacted"
if stream == "acmeCo/tags":
rec["name"] = "redacted"
# Updating count with rec["count"] = 1 sets count to be
# the tuple [1] instead of the int 1. We can get around
# this by deleting the attribute then re-setting it.
del rec["count"]
rec["count"] = 1


assert snapshot("capture.stdout.json") == unique_stream_lines
Expand Down
Loading