I’m attempting to use a for loop to save myself some typing with inspec. My first attemtp looks like this:
for i in 1..2
describe group('testgroup#{i}') do
it { should exist }
end
end
But inspec doesn’t seem to like that:
Group testgroup#{i}
∅ should exist
expected Group testgroup#{i} to exist
Group testgroup#{i}
∅ should exist
expected Group testgroup#{i} to exist
I’m a bit of a n00b in Ruby, but it somes from an example which seems to be correct.
Any help appreciated