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

Potential bug #195

Open
pderouen opened this issue Apr 27, 2023 · 1 comment
Open

Potential bug #195

pderouen opened this issue Apr 27, 2023 · 1 comment
Assignees
Labels

Comments

@pderouen
Copy link
Member

def header
if smt8?
@test_path = []
l = 'Test Suite,Test,Test Number,Test Text'
if test_modes.empty?
l += ',Low Limit,High Limit'
else
l += ',Low Limit'
(test_modes.size - 1).times { l += ',' }
l += ',High Limit'
(test_modes.size - 1).times { l += ',' }
end
l += ',Unit,Soft Bin'
lines << l
l = ',,,'
if test_modes.empty?
l += ',default,default'
else
test_modes.each { |mode| l += ",#{mode}" }
test_modes.each { |mode| l += ",#{mode}" }
end
lines << l

The new lint rules want the loops on line 38 and 39 combined into 1 loop. I am going to disable the check to leave the code as is. But, wanted to raise it as a potential bug. Is the duplication intended?

@priyavadan
Copy link
Member

seems like an oversight, should only need 1 of them , imo.

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

No branches or pull requests

4 participants