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

feat: Validate records against stream schema in standard tap tests #1711

Conversation

edgarrmondragon
Copy link
Collaborator

@edgarrmondragon edgarrmondragon commented May 17, 2023

Failure example:

FAILED tests/external/test_tap_gitlab.py::TestSampleTapGitlab::test_tap_stream_record_matches_stream_schema[epic_issues] - AssertionError: Record does not match stream schema: '2021-11-03T15:21:07.350Z' is not of type 'null' (path: closed_at)
'flow::Review' is not of type 'object' (path: labels.0)
'kind::Feature' is not of type 'object' (path: labels.1)
'valuestream::Hub' is not of type 'object' (path: labels.2)
'2021-11-05' is not of type 'null' (path: milestone.due_date)
'2021-10-30' is not of type 'null' (path: milestone.start_date)
'project_id' is a required property (path: milestone)
FAILED tests/external/test_tap_gitlab.py::TestSampleTapGitlab::test_tap_stream_record_matches_stream_schema[issues] - AssertionError: Record does not match stream schema: {'id': 1134865, 'username': 'edgarrmondragon', 'name': 'Edgar R. Mondragón', 'state': 'active', 'avatar_url': 'https://gitlab.com/uploads/-/system/user/avatar/1134865/avatar.png', 'web_url': 'https://gitlab.com/edgarrmondragon'} is not of type 'integer' (path: assignees.0)

📚 Documentation preview 📚: https://meltano-sdk--1711.org.readthedocs.build/en/1711/

@edgarrmondragon edgarrmondragon linked an issue May 17, 2023 that may be closed by this pull request
@codecov
Copy link

codecov bot commented May 17, 2023

Codecov Report

Merging #1711 (91818f1) into main (8b76d8a) will increase coverage by 0.03%.
The diff coverage is 100.00%.

❗ Current head 91818f1 differs from pull request most recent head 9e2dd94. Consider uploading reports for the commit 9e2dd94 to get more accurate results

@@            Coverage Diff             @@
##             main    #1711      +/-   ##
==========================================
+ Coverage   85.08%   85.11%   +0.03%     
==========================================
  Files          59       59              
  Lines        4868     4878      +10     
  Branches      807      809       +2     
==========================================
+ Hits         4142     4152      +10     
  Misses        527      527              
  Partials      199      199              
Impacted Files Coverage Δ
singer_sdk/testing/suites.py 100.00% <ø> (ø)
singer_sdk/testing/tap_tests.py 83.73% <100.00%> (+1.43%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@edgarrmondragon edgarrmondragon force-pushed the 1710-feat-catch-mismatched-field-data-types-in-standard-tap-tests branch from c8ad56d to ea10d69 Compare May 17, 2023 20:52
@edgarrmondragon edgarrmondragon marked this pull request as ready for review May 17, 2023 21:24
@edgarrmondragon edgarrmondragon requested a review from kgpayne as a code owner May 17, 2023 21:24
@edgarrmondragon edgarrmondragon merged commit 973f245 into main May 18, 2023
@edgarrmondragon edgarrmondragon deleted the 1710-feat-catch-mismatched-field-data-types-in-standard-tap-tests branch May 18, 2023 13:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: Catch mismatched field data types in standard tap tests
2 participants