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

Clarify test methods for integration tests and testing in general #137

Closed
iamogbz opened this issue Feb 29, 2020 · 3 comments · Fixed by #394
Closed

Clarify test methods for integration tests and testing in general #137

iamogbz opened this issue Feb 29, 2020 · 3 comments · Fixed by #394
Labels
feature request New feature or request released
Milestone

Comments

@iamogbz
Copy link
Collaborator

iamogbz commented Feb 29, 2020

Current tests are starting to be hard to reason about. Some clarification about the behaviour each test is attempting to verify is getting more essential.

Describe the solution you'd like

Make each test case group a single file testing all the behaviours with module and test doc string explaining the purpose

Describe alternatives you've considered
N/A

Additional context
The tests/test_integration_default.py file is an example of this complexity.

@iamogbz iamogbz added the feature request New feature or request label Feb 29, 2020
@noahnu noahnu added this to the v1.0.0 milestone Sep 10, 2020
@iamogbz
Copy link
Collaborator Author

iamogbz commented Oct 9, 2020

@noahnu how about naming files based on what they test and splitting off when each file testing scope gets too large

tests/
  integration/
    test_snapshot_option_default_extension.py
    test_snapshot_option_no_colors.py
    test_snapshot_option_update.py
    test_snapshot_option_warn_unused.py
    utils.py # containing stuff like "find_snapshot_summary_in_result"
  unit/
    extensions/
      amber/
        test_amber_filters.py # with use of filters
        test_amber_matchers.py # with use of matchers
        test_amber_serializer.py # containing the different data types supported and parametrized
      image/
        test_image_png.py
        test_image_svg.py
      test_base.py
      test_single_file.py
    test_data.py
    test_location.py
    test_report.py
    test_session.py
    test_utils.py

@noahnu
Copy link
Collaborator

noahnu commented Oct 9, 2020

Yeah that looks good 👍

@syrupy-bot
Copy link
Contributor

🎉 This issue has been resolved in version 0.8.2 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants