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

Split test fixtures into different folders per algorithm #479

Closed
nicoburns opened this issue May 15, 2023 · 6 comments · Fixed by #514
Closed

Split test fixtures into different folders per algorithm #479

nicoburns opened this issue May 15, 2023 · 6 comments · Fixed by #514
Labels
good first issue Good for newcomers testing Additional tests or improvements to the testing infrastructure

Comments

@nicoburns
Copy link
Collaborator

nicoburns commented May 15, 2023

What do you think about splitting the test_fixtures (and corresponding generated files) into multiple folders?
I think one folder per algorithm and maybe one for mixed tests would be useful to organize things a bit.
I'm not sure how hard that would be to integrate in the generation script though.

Originally posted by @TimJentzsch in #474 (review)

This would give us the following folders:

  • flex
  • grid
  • block
  • leaf
  • gridflex
  • blockflex
  • blockgrid

Note:grid, block and leaf algorithm tests are prefixed with grid/block/leaf. The remaining unprefixed tests are all flexbox tests. We would likely also need to reorganise the generated tests themselves a little. Perhaps by nesting them in modules corresponding to the directory they originate in.

@nicoburns nicoburns added good first issue Good for newcomers testing Additional tests or improvements to the testing infrastructure labels May 15, 2023
@aemreaydin
Copy link
Contributor

I would like to work on this issue. This is going to be my first issue on taffy but I think I have a simple understanding of what needs to be done here.

  1. Move files prefixed with the given categories (flex, grid, etc.) in test_fixtures into their respective categories. Unprefixed ones can go into the flex folder.
  2. Update the gentest code to respect the file structure when generating the tests.

@alice-i-cecile
Copy link
Collaborator

Sounds great: let us know if you have any questions :)

@nicoburns
Copy link
Collaborator Author

Your understanding sounds correct to me. One detail I would add is that there are two aspects to part 2:

  • The test generation script needs to be updated to look for test fixtures in their new nested locations
  • The test generation script (probably) needs to be updated to output tests in nested modules.

@aemreaydin
Copy link
Contributor

Sounds good, that's what I was thinking as well. Will let you know if I have quetsions.

@aemreaydin
Copy link
Contributor

Two questions;

  1. Should I keep the files prefixed with "x" in the test_fixtures folder?
  2. To recursively work with the directory, can I add the walkdir crate?

@nicoburns
Copy link
Collaborator Author

Should I keep the files prefixed with "x" in the test_fixtures folder?

Yes. These are tests that are temporarily disabled, but that we hope to be enable later. They should be grouped under the directory that would be in if they didn't have the x prefix, but the x prefix should be retained

To recursively work with the directory, can I add the walkdir crate?

Yes, that's fine :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers testing Additional tests or improvements to the testing infrastructure
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants