TST: add tests validating primitive input_types shapes#2773
Conversation
Adds four parametrised tests (run against all 203 primitives) that
assert the contracts the codebase relies on for input_types:
1. The list is never empty.
2. Items are either all ColumnSchema (flat) or all list (nested),
never a mix of the two.
3. When nested, all sub-lists are the same length.
4. When nested, no sub-list is empty.
Closes alteryx#2086
|
Lakshmi786 seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
|
Hi team! 👋 I am a ML/Data Science engineer working on improving open-source tooling. I noticed issue #2086 had been open for a while with no test coverage for What this PR addsFour parametrised pytest tests that run against all 203 registered primitives and assert the contracts the codebase relies on for
All 812 generated test cases pass on the current codebase. Happy to adjust the test style, naming, or scope based on your feedback. Let me know if you'd like me to also add these checks to the Thanks for maintaining such a great library! |
Summary
Adds four parametrised pytest tests that validate the shape contracts
for
input_typesacross all 203 registered primitives.Contracts tested:
input_typesis never emptyColumnSchema(flat) orlist(nested) — never mixedAll 812 generated test cases pass on the current codebase.
Closes #2086