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

Fix colormap utils error suggestion code and add a test #5571

Merged
merged 5 commits into from
Feb 21, 2023

Conversation

goanpeca
Copy link
Contributor

@goanpeca goanpeca commented Feb 18, 2023

Description

Type of change

  • Bug-fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

References

How has this been tested?

  • example: the test suite for my feature covers cases x, y, and z
  • example: all tests pass with my change
  • example: I check if my changes works with both PySide and PyQt backends
    as there are small differences between the two Qt bindings.

Final checklist:

  • My PR is the minimum possible work for the desired functionality
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • If I included new strings, I have used trans. to make them localizable.
    For more information see our translations guide.

@github-actions github-actions bot added the tests Something related to our tests label Feb 18, 2023
@codecov
Copy link

codecov bot commented Feb 18, 2023

Codecov Report

Merging #5571 (0c03940) into main (151ca9c) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##             main    #5571   +/-   ##
=======================================
  Coverage   89.40%   89.41%           
=======================================
  Files         609      609           
  Lines       51170    51168    -2     
=======================================
  Hits        45750    45750           
+ Misses       5420     5418    -2     
Impacted Files Coverage Δ
napari/utils/colormaps/colormap_utils.py 93.20% <ø> (ø)
napari/utils/colormaps/_tests/test_colormaps.py 100.00% <100.00%> (ø)
napari/components/_tests/test_layer_slicer.py 97.98% <0.00%> (-1.21%) ⬇️
napari/_qt/dialogs/qt_package_installer.py 81.81% <0.00%> (+0.39%) ⬆️
napari/utils/theme.py 94.04% <0.00%> (+0.59%) ⬆️
napari/utils/info.py 85.10% <0.00%> (+1.06%) ⬆️
napari/_qt/__init__.py 56.66% <0.00%> (+6.66%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@jni jni added the ready to merge Last chance for comments! Will be merged in ~24h label Feb 18, 2023
Copy link
Collaborator

@Czaki Czaki left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I prefer to use match instead string assertions, but I'm ok with both.

napari/utils/colormaps/_tests/test_colormaps.py Outdated Show resolved Hide resolved
napari/utils/colormaps/_tests/test_colormaps.py Outdated Show resolved Hide resolved
napari/utils/colormaps/_tests/test_colormaps.py Outdated Show resolved Hide resolved
napari/utils/colormaps/_tests/test_colormaps.py Outdated Show resolved Hide resolved
goanpeca and others added 2 commits February 18, 2023 11:48
Co-authored-by: Grzegorz Bokota <bokota+github@gmail.com>
@goanpeca
Copy link
Contributor Author

goanpeca commented Feb 18, 2023

I prefer to use match instead string assertions, but I'm ok with both.

TIL :) that is pretty cool, thanks for the suggestion!

@goanpeca goanpeca requested a review from Czaki February 18, 2023 17:22
@Czaki Czaki merged commit 0e08cb1 into napari:main Feb 21, 2023
@Czaki Czaki removed the ready to merge Last chance for comments! Will be merged in ~24h label Feb 21, 2023
@Czaki Czaki mentioned this pull request Jun 7, 2023
@Czaki Czaki added this to the 0.4.18 milestone Jun 16, 2023
@Czaki Czaki added the bugfix PR with bugfix label Jun 16, 2023
Czaki added a commit that referenced this pull request Jun 18, 2023
Co-authored-by: Grzegorz Bokota <bokota+github@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Czaki added a commit that referenced this pull request Jun 19, 2023
Co-authored-by: Grzegorz Bokota <bokota+github@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Czaki added a commit that referenced this pull request Jun 21, 2023
Co-authored-by: Grzegorz Bokota <bokota+github@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Czaki added a commit that referenced this pull request Jun 21, 2023
Co-authored-by: Grzegorz Bokota <bokota+github@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Czaki added a commit that referenced this pull request Jun 21, 2023
Co-authored-by: Grzegorz Bokota <bokota+github@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix PR with bugfix tests Something related to our tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants