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 read_callback user provided input case (in)sensitivity #352

Conversation

realvitya
Copy link
Contributor

Description

This PR is about to handle the situation when user provides input for contains or not_contains with capital letters while case_insensitive attribute only lowers device input's case. Previously, input is not matched though the difference is only letter case. This fix basically lowers user input strings if case_insensitive is True and string in operator will work as intended.

Type of change

Please delete options that are not relevant.

  • 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

How Has This Been Tested?

pytest case added in line with the spirit of the project owner.

Checklist:

  • My code follows the style guidelines of this project (no GitHub actions complaints! run make lint before
    committing!)
  • I have commented my code, pydocstyle and darglint are happy, docstrings are in google docstring format, and all
    docstrings include a summary, args, returns and raises fields (even if N/A)
  • I have added tests that prove my fix is effective or that my feature works, if adding "functional" tests please
    note if there are any considerations for the vrnetlab setup
  • New and existing unit tests pass locally with my changes

@carlmontanari
Copy link
Owner

@realvitya thank you as always!! LGTM!

@carlmontanari carlmontanari merged commit 50680e8 into carlmontanari:main Oct 11, 2024
12 checks passed
@realvitya realvitya deleted the fix/read_callback-case-insensitive-for-contains branch October 12, 2024 10:16
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