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

First pass at converting test -> tests sections, some outputs conversion work #114

Merged
merged 4 commits into from
Feb 26, 2024

Conversation

schuylermartin45
Copy link
Collaborator

@schuylermartin45 schuylermartin45 commented Feb 22, 2024

old_to_new_recipe_tests_mapping_diagram
See the badly-hand-drawn diagram above for a rough outline of what is being done ^

This is the first-pass at converting the old test recipe section to the new tests recipe section. All test sections should be converted, regardless if the recipe produces single or multiple outputs.

Most keys map directly to newer counter parts. If a pip check command is listed under commands, it is upgraded to the new tests/python/pip-check flag. If it not found, the flag is set to false.

For now, only exact matches for - pip check are converted, with no special logic for handling selectors. This should cover the vast majority of recipes (at least from AnacondaRecipes).

The top-level keys found in the tests section are then canonically sorted, based on the ordering found in CEP-14.

Unit tests have been modified as needed.

EDIT: I was working on some of the outputs conversion work and it looked pretty straight forward, so I've added some of that into this PR.

- Starts work on transforming the old to the new test section format
  - Most transformations appear to be simple relocations
- Breaks unit tests, they'll need to be updated later
- Maps the old test section values to their new equivalents
- Includes some minor refactoring of repeated work with new convenience
  functions
- Modifies unit tests
Upon further reflection, the comment recovery system won't be very useful.
This commit simplifies some logic and now comments that have been dropped are
logged as WARNINGS only.
- This starts some (but I don't think all) of the conversions required for
  the `outputs` section
- This was easier than I expected, so I'm going to add it to the existing PR
@schuylermartin45 schuylermartin45 changed the title First pass at converting test -> tests sections First pass at converting test -> tests sections, some outputs conversion work Feb 23, 2024
@schuylermartin45 schuylermartin45 merged commit 072bea4 into main Feb 26, 2024
3 checks passed
@schuylermartin45 schuylermartin45 deleted the smartin_starting_test_section_transforms branch February 26, 2024 18: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.

2 participants