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

wrote test function for _is_node_field_valid() #224

Merged
merged 1 commit into from
Jul 26, 2023

Conversation

nh916
Copy link
Contributor

@nh916 nh916 commented Jul 25, 2023

Description

this function was missing a test case and since I am thinking of refactoring it soon, test cases would be really helpful with that and being sure that the project works well anyways

Changes

  • wrote test function and test cases for _is_node_field_valid()
  • made a change that if the field is a list, but the string inside is empty then it is invalid

Tests

Known Issues

Notes

Checklist

  • My name is on the list of contributors (CONTRIBUTORS.md) in the pull request source branch.
  • I have updated the documentation to reflect my changes.

wrote test function and test cases for `_is_node_field_valid`
@trunk-io
Copy link

trunk-io bot commented Jul 25, 2023

Merging to develop in this repository is managed by Trunk.

  • To merge this pull request, check the box to the left or comment /trunk merge below.

@nh916 nh916 changed the title wrote test function for _is_node_field_valid wrote test function for _is_node_field_valid() Jul 25, 2023
@nh916 nh916 requested a review from InnocentBug July 25, 2023 23:30
@nh916
Copy link
Contributor Author

nh916 commented Jul 25, 2023

@InnocentBug I was thinking of wrapping the function with a @beartype so that it could give us errors in case we give it a wrong type of input at some point within our code. What are your thoughts?

@InnocentBug
Copy link
Collaborator

this is excellent

@nh916
Copy link
Contributor Author

nh916 commented Jul 26, 2023

this is excellent

Thank you so much!

If you can think of more test cases feel free to add them.

@nh916 nh916 merged commit cd268c8 into develop Jul 26, 2023
14 checks passed
@nh916 nh916 deleted the test_is_node_field_valid branch July 26, 2023 18:40
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