Closed Sliim closed 9 years ago
Example of generated file (in specs):
12) ssh_config resource when non-default attributes are used can handle a custom path
Failure/Error: expect(chef_run).to render_file(test_config).with_content(
expected Chef run to render "/some/random/path/config" matching:
# Created by Chef for chefspec.local
Host somewhere
not indented
and_also_with =equal sign
Host second with extra patterns
Extra_spaces did_not_matter
HostName option is correctly matched
Multiple_words not a problem
We "can handle quotes"
Host test.io
User testuser
DummyKey I was allowed
but got:
# Created by Chef for chefspec.local
Host somewhere
not indented
and_also_with =equal sign
Host second with extra patterns
Extra_spaces did_not_matter
Host Name option is correctly matched
Multiple_words not a problem
We "can handle quotes"
Host test.io
User testuser
DummyKey I was allowed
# ./spec/provider_tests/config_spec.rb:207:in `block (3 levels) in <top (required)>')
Thanks @Sliim this is now in the v0.10.2 which was released to the supermarket today.
:+1: Thanks for your work! :)
Old regex match "HostName ..." as a Host entry that generate an invalid ssh configuration file.