1
0
mirror of synced 2026-01-01 00:02:54 -05:00
Commit Graph

5 Commits

Author SHA1 Message Date
Sherif A. Nada
1fb6b9f911 CDK: test catalog helpers (#3271)
* test catalog helpers

* Format.

Co-authored-by: Davin Chia <davinchia@gmail.com>
2021-05-07 22:12:52 +08:00
Sherif A. Nada
f88e5de903 Test Source Entrypoint Arg Parsing (#3259) 2021-05-06 15:34:55 -07:00
Sherif A. Nada
e856502455 CDK: Test integration.py (#3243)
* integration.py tests

* refactor integration.py

Co-authored-by: Davin Chia <davinchia@gmail.com>
2021-05-06 18:25:10 +08:00
Davin Chia
b5c2329748 CDK: Add OAuth and Streams/Core tests. (#3228)
Completely test the OAuth module and streams/core.py file.

Add pytest-mock as well as a convenience wrapper to run the type checker and the test together when developing.

Also configure pytest to pick up loggers at the INFO level and above, and pick up standard out for easier debugging.

Some of the script bits are unpolished - will improve them as we go along.
2021-05-06 15:52:23 +08:00
Sherif A. Nada
c3356684dd Test JSONSchema resolver (#3223)
closes #2722

I don't love the current structure. There is a number of improvements that can be made:

JsonSchemaResolver can be refactored to have the following signature:

def __init__(schemas: Mapping[str, any], refs: Mapping[str, any])
  # schemas are all json files in `schemas/`, refs are all json files in `schemas/shared/`
Then we can thoroughly test the resolving behavior in JsonSchemaResolver independently from the logic for where we actually load schemas from.

I was tempted to make this refactor now but I'd rather cover more ground with tests then revisit. I created an issue to track this: #3222
2021-05-05 09:51:24 +08:00