Skip to content

Conversation

@vnktshr21
Copy link
Contributor

  • This contribution adheres to CONTRIBUTING.md.
  • I've updated CHANGELOG.md if applicable.
  • I've added tests applicable for this pull request

What does this Pull Request accomplish?

convert_list_to_comma_separated_string converter now checks if the input is a list of str and raise a TypeError if its not, so that we do not accidentally take in any other type of input and do a join on that in case of writeable attributes using this type.

List issues fixed by this Pull Request below, if any.

convert_list_to_comma_separated_string was assuming a list input, which could be wrong.

What testing has been done?

Add a nifake unit test to confirm that TypeError is thrown.

@codecov-commenter
Copy link

codecov-commenter commented Jan 7, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.08%. Comparing base (442e169) to head (6cf9c8c).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #2154   +/-   ##
=======================================
  Coverage   90.07%   90.08%           
=======================================
  Files          71       71           
  Lines       18664    18666    +2     
=======================================
+ Hits        16812    16815    +3     
+ Misses       1852     1851    -1     
Flag Coverage Δ
codegenunittests 84.44% <ø> (ø)
nidcpowersystemtests 94.65% <ø> (+0.04%) ⬆️
nidcpowerunittests 89.53% <ø> (ø)
nidigitalsystemtests 92.26% <ø> (ø)
nidigitalunittests 68.44% <ø> (ø)
nidmmsystemtests 92.72% <ø> (ø)
nifakeunittests 85.51% <100.00%> (+0.02%) ⬆️
nifgensystemtests 94.61% <ø> (ø)
nimodinstsystemtests 73.85% <ø> (ø)
nimodinstunittests 94.20% <ø> (ø)
nirfsgsystemtests 82.40% <ø> (ø)
niscopesystemtests 92.94% <ø> (ø)
niscopeunittests 43.20% <ø> (ø)
nisesystemtests 91.50% <ø> (ø)
niswitchsystemtests 82.03% <ø> (ø)
nitclksystemtests 94.87% <ø> (ø)
nitclkunittests 98.26% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
generated/nifake/nifake/_converters.py 95.65% <100.00%> (+0.06%) ⬆️

... and 2 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 442e169...6cf9c8c. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ni-jfitzger ni-jfitzger changed the title raise typeerror if input is not list of str for convert_list_to_comma_separated_string converter raise TypeError if input is not list of str for convert_list_to_comma_separated_string converter Jan 7, 2026
@ni-jfitzger ni-jfitzger merged commit 36c7150 into ni:master Jan 8, 2026
39 checks passed
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.

3 participants