serverspec 0.7.10 → 0.7.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/serverspec/commands/base.rb +12 -2
- data/lib/serverspec/commands/solaris.rb +4 -2
- data/lib/serverspec/version.rb +1 -1
- data/spec/darwin/file_spec.rb +5 -5
- data/spec/debian/file_spec.rb +5 -5
- data/spec/gentoo/file_spec.rb +5 -5
- data/spec/redhat/file_spec.rb +5 -5
- data/spec/solaris/file_spec.rb +5 -5
- data/spec/solaris11/file_spec.rb +5 -5
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c971f7ffde09d489689464ca4c19537dc2732cfc
|
4
|
+
data.tar.gz: 33def92c5874f2b856f300f4bf1575f02cf553cc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dfaa2f7870f797adea5392280d35e6cb79e2faef78e3492f2152bf1a174c5c99c8d17827dc4581f8aa45ee07222dd78bcb0d5f8c4bf688df1e4e48b36fd54210
|
7
|
+
data.tar.gz: 9eb049438d22bb921cdb570c79443b5d0f3791db92ee37908d2126b3507fcd186442070a987bedfd7987808a4cb3d2fbe653b2eb4d9192e4339fb9e8492f99c3
|
@@ -114,9 +114,17 @@ module Serverspec
|
|
114
114
|
end
|
115
115
|
|
116
116
|
def check_file_contain(file, expected_pattern)
|
117
|
+
"#{check_file_contain_with_regexp(file, expected_pattern)} || #{check_file_contain_with_fixed_strings(file, expected_pattern)}"
|
118
|
+
end
|
119
|
+
|
120
|
+
def check_file_contain_with_regexp(file, expected_pattern)
|
117
121
|
"grep -q -- #{escape(expected_pattern)} #{escape(file)}"
|
118
122
|
end
|
119
123
|
|
124
|
+
def check_file_contain_with_fixed_strings(file, expected_pattern)
|
125
|
+
"grep -qF -- #{escape(expected_pattern)} #{escape(file)}"
|
126
|
+
end
|
127
|
+
|
120
128
|
def check_file_md5checksum(file, expected)
|
121
129
|
regexp = "^#{expected}"
|
122
130
|
"md5sum #{escape(file)} | grep -iw -- #{escape(regexp)}"
|
@@ -130,8 +138,10 @@ module Serverspec
|
|
130
138
|
def check_file_contain_within(file, expected_pattern, from=nil, to=nil)
|
131
139
|
from ||= '1'
|
132
140
|
to ||= '$'
|
133
|
-
|
134
|
-
|
141
|
+
sed = "sed -n #{escape(from)},#{escape(to)}p #{escape(file)}"
|
142
|
+
checker_with_regexp = check_file_contain_with_regexp("-", expected_pattern)
|
143
|
+
checker_with_fixed = check_file_contain_with_fixed_strings("-", expected_pattern)
|
144
|
+
"#{sed} | #{checker_with_regexp} || #{sed} | #{checker_with_fixed}"
|
135
145
|
end
|
136
146
|
|
137
147
|
def check_mode(file, mode)
|
@@ -75,8 +75,10 @@ module Serverspec
|
|
75
75
|
def check_file_contain_within(file, expected_pattern, from=nil, to=nil)
|
76
76
|
from ||= '1'
|
77
77
|
to ||= '$'
|
78
|
-
|
79
|
-
|
78
|
+
sed = "sed -n #{escape(from)},#{escape(to)}p #{escape(file)}"
|
79
|
+
checker_with_regexp = check_file_contain_with_regexp("/dev/stdin", expected_pattern)
|
80
|
+
checker_with_fixed = check_file_contain_with_fixed_strings("/dev/stdin", expected_pattern)
|
81
|
+
"#{sed} | #{checker_with_regexp} || #{sed} | #{checker_with_fixed}"
|
80
82
|
end
|
81
83
|
|
82
84
|
def check_belonging_group(user, group)
|
data/lib/serverspec/version.rb
CHANGED
data/spec/darwin/file_spec.rb
CHANGED
@@ -31,12 +31,12 @@ end
|
|
31
31
|
|
32
32
|
describe file('/etc/ssh/sshd_config') do
|
33
33
|
it { should contain 'This is the sshd server system-wide configuration file' }
|
34
|
-
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
34
|
+
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
35
35
|
end
|
36
36
|
|
37
37
|
describe file('/etc/ssh/sshd_config') do
|
38
38
|
it { should contain /^This is the sshd server system-wide configuration file/ }
|
39
|
-
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config"
|
39
|
+
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config"}
|
40
40
|
end
|
41
41
|
|
42
42
|
describe file('/etc/ssh/sshd_config') do
|
@@ -45,7 +45,7 @@ end
|
|
45
45
|
|
46
46
|
describe file('Gemfile') do
|
47
47
|
it { should contain('rspec').from(/^group :test do/).to(/^end/) }
|
48
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec -" }
|
48
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec - || sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -qF -- rspec -" }
|
49
49
|
end
|
50
50
|
|
51
51
|
describe file('/etc/ssh/sshd_config') do
|
@@ -54,7 +54,7 @@ end
|
|
54
54
|
|
55
55
|
describe file('Gemfile') do
|
56
56
|
it { should contain('rspec').after(/^group :test do/) }
|
57
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec -" }
|
57
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec - || sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -qF -- rspec -" }
|
58
58
|
end
|
59
59
|
|
60
60
|
describe file('/etc/ssh/sshd_config') do
|
@@ -63,7 +63,7 @@ end
|
|
63
63
|
|
64
64
|
describe file('Gemfile') do
|
65
65
|
it { should contain('rspec').before(/^end/) }
|
66
|
-
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec -" }
|
66
|
+
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec - || sed -n 1,/\\^end/p Gemfile | grep -qF -- rspec -" }
|
67
67
|
end
|
68
68
|
|
69
69
|
describe file('/etc/ssh/sshd_config') do
|
data/spec/debian/file_spec.rb
CHANGED
@@ -31,12 +31,12 @@ end
|
|
31
31
|
|
32
32
|
describe file('/etc/ssh/sshd_config') do
|
33
33
|
it { should contain 'This is the sshd server system-wide configuration file' }
|
34
|
-
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
34
|
+
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
35
35
|
end
|
36
36
|
|
37
37
|
describe file('/etc/ssh/sshd_config') do
|
38
38
|
it { should contain /^This is the sshd server system-wide configuration file/ }
|
39
|
-
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
39
|
+
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
40
40
|
end
|
41
41
|
|
42
42
|
describe file('/etc/ssh/sshd_config') do
|
@@ -45,7 +45,7 @@ end
|
|
45
45
|
|
46
46
|
describe file('Gemfile') do
|
47
47
|
it { should contain('rspec').from(/^group :test do/).to(/^end/) }
|
48
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec -" }
|
48
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec - || sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -qF -- rspec -" }
|
49
49
|
end
|
50
50
|
|
51
51
|
describe file('/etc/ssh/sshd_config') do
|
@@ -54,7 +54,7 @@ end
|
|
54
54
|
|
55
55
|
describe file('Gemfile') do
|
56
56
|
it { should contain('rspec').after(/^group :test do/) }
|
57
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec -" }
|
57
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec - || sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -qF -- rspec -" }
|
58
58
|
end
|
59
59
|
|
60
60
|
describe file('/etc/ssh/sshd_config') do
|
@@ -63,7 +63,7 @@ end
|
|
63
63
|
|
64
64
|
describe file('Gemfile') do
|
65
65
|
it { should contain('rspec').before(/^end/) }
|
66
|
-
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec -" }
|
66
|
+
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec - || sed -n 1,/\\^end/p Gemfile | grep -qF -- rspec -" }
|
67
67
|
end
|
68
68
|
|
69
69
|
describe file('/etc/ssh/sshd_config') do
|
data/spec/gentoo/file_spec.rb
CHANGED
@@ -31,12 +31,12 @@ end
|
|
31
31
|
|
32
32
|
describe file('/etc/ssh/sshd_config') do
|
33
33
|
it { should contain 'This is the sshd server system-wide configuration file' }
|
34
|
-
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
34
|
+
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
35
35
|
end
|
36
36
|
|
37
37
|
describe file('/etc/ssh/sshd_config') do
|
38
38
|
it { should contain /^This is the sshd server system-wide configuration file/ }
|
39
|
-
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
39
|
+
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
40
40
|
end
|
41
41
|
|
42
42
|
describe file('/etc/ssh/sshd_config') do
|
@@ -45,7 +45,7 @@ end
|
|
45
45
|
|
46
46
|
describe file('Gemfile') do
|
47
47
|
it { should contain('rspec').from(/^group :test do/).to(/^end/) }
|
48
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec -" }
|
48
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec - || sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -qF -- rspec -" }
|
49
49
|
end
|
50
50
|
|
51
51
|
describe file('/etc/ssh/sshd_config') do
|
@@ -54,7 +54,7 @@ end
|
|
54
54
|
|
55
55
|
describe file('Gemfile') do
|
56
56
|
it { should contain('rspec').after(/^group :test do/) }
|
57
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec -" }
|
57
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec - || sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -qF -- rspec -" }
|
58
58
|
end
|
59
59
|
|
60
60
|
describe file('/etc/ssh/sshd_config') do
|
@@ -63,7 +63,7 @@ end
|
|
63
63
|
|
64
64
|
describe file('Gemfile') do
|
65
65
|
it { should contain('rspec').before(/^end/) }
|
66
|
-
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec -" }
|
66
|
+
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec - || sed -n 1,/\\^end/p Gemfile | grep -qF -- rspec -" }
|
67
67
|
end
|
68
68
|
|
69
69
|
describe file('/etc/ssh/sshd_config') do
|
data/spec/redhat/file_spec.rb
CHANGED
@@ -31,12 +31,12 @@ end
|
|
31
31
|
|
32
32
|
describe file('/etc/ssh/sshd_config') do
|
33
33
|
it { should contain 'This is the sshd server system-wide configuration file' }
|
34
|
-
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
34
|
+
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
35
35
|
end
|
36
36
|
|
37
37
|
describe file('/etc/ssh/sshd_config') do
|
38
38
|
it { should contain /^This is the sshd server system-wide configuration file/ }
|
39
|
-
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
39
|
+
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
40
40
|
end
|
41
41
|
|
42
42
|
describe file('/etc/ssh/sshd_config') do
|
@@ -45,7 +45,7 @@ end
|
|
45
45
|
|
46
46
|
describe file('Gemfile') do
|
47
47
|
it { should contain('rspec').from(/^group :test do/).to(/^end/) }
|
48
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec -" }
|
48
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec - || sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -qF -- rspec -" }
|
49
49
|
end
|
50
50
|
|
51
51
|
describe file('/etc/ssh/sshd_config') do
|
@@ -54,7 +54,7 @@ end
|
|
54
54
|
|
55
55
|
describe file('Gemfile') do
|
56
56
|
it { should contain('rspec').after(/^group :test do/) }
|
57
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec -" }
|
57
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec - || sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -qF -- rspec -" }
|
58
58
|
end
|
59
59
|
|
60
60
|
describe file('/etc/ssh/sshd_config') do
|
@@ -63,7 +63,7 @@ end
|
|
63
63
|
|
64
64
|
describe file('Gemfile') do
|
65
65
|
it { should contain('rspec').before(/^end/) }
|
66
|
-
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec -" }
|
66
|
+
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec - || sed -n 1,/\\^end/p Gemfile | grep -qF -- rspec -" }
|
67
67
|
end
|
68
68
|
|
69
69
|
describe file('/etc/ssh/sshd_config') do
|
data/spec/solaris/file_spec.rb
CHANGED
@@ -31,12 +31,12 @@ end
|
|
31
31
|
|
32
32
|
describe file('/etc/ssh/sshd_config') do
|
33
33
|
it { should contain 'This is the sshd server system-wide configuration file' }
|
34
|
-
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
34
|
+
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
35
35
|
end
|
36
36
|
|
37
37
|
describe file('/etc/ssh/sshd_config') do
|
38
38
|
it { should contain /^This is the sshd server system-wide configuration file/ }
|
39
|
-
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
39
|
+
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
40
40
|
end
|
41
41
|
|
42
42
|
describe file('/etc/ssh/sshd_config') do
|
@@ -45,7 +45,7 @@ end
|
|
45
45
|
|
46
46
|
describe file('Gemfile') do
|
47
47
|
it { should contain('rspec').from(/^group :test do/).to(/^end/) }
|
48
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec /dev/stdin" }
|
48
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec /dev/stdin || sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -qF -- rspec /dev/stdin" }
|
49
49
|
end
|
50
50
|
|
51
51
|
describe file('/etc/ssh/sshd_config') do
|
@@ -54,7 +54,7 @@ end
|
|
54
54
|
|
55
55
|
describe file('Gemfile') do
|
56
56
|
it { should contain('rspec').after(/^group :test do/) }
|
57
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec /dev/stdin" }
|
57
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec /dev/stdin || sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -qF -- rspec /dev/stdin" }
|
58
58
|
end
|
59
59
|
|
60
60
|
describe file('/etc/ssh/sshd_config') do
|
@@ -63,7 +63,7 @@ end
|
|
63
63
|
|
64
64
|
describe file('Gemfile') do
|
65
65
|
it { should contain('rspec').before(/^end/) }
|
66
|
-
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec /dev/stdin" }
|
66
|
+
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec /dev/stdin || sed -n 1,/\\^end/p Gemfile | grep -qF -- rspec /dev/stdin" }
|
67
67
|
end
|
68
68
|
|
69
69
|
describe file('/etc/ssh/sshd_config') do
|
data/spec/solaris11/file_spec.rb
CHANGED
@@ -31,12 +31,12 @@ end
|
|
31
31
|
|
32
32
|
describe file('/etc/ssh/sshd_config') do
|
33
33
|
it { should contain 'This is the sshd server system-wide configuration file' }
|
34
|
-
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
34
|
+
its(:command) { should eq "grep -q -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
35
35
|
end
|
36
36
|
|
37
37
|
describe file('/etc/ssh/sshd_config') do
|
38
38
|
it { should contain /^This is the sshd server system-wide configuration file/ }
|
39
|
-
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
39
|
+
its(:command) { should eq "grep -q -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config || grep -qF -- \\^This\\ is\\ the\\ sshd\\ server\\ system-wide\\ configuration\\ file /etc/ssh/sshd_config" }
|
40
40
|
end
|
41
41
|
|
42
42
|
describe file('/etc/ssh/sshd_config') do
|
@@ -45,7 +45,7 @@ end
|
|
45
45
|
|
46
46
|
describe file('Gemfile') do
|
47
47
|
it { should contain('rspec').from(/^group :test do/).to(/^end/) }
|
48
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec /dev/stdin" }
|
48
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -q -- rspec /dev/stdin || sed -n /\\^group\\ :test\\ do/,/\\^end/p Gemfile | grep -qF -- rspec /dev/stdin" }
|
49
49
|
end
|
50
50
|
|
51
51
|
describe file('/etc/ssh/sshd_config') do
|
@@ -54,7 +54,7 @@ end
|
|
54
54
|
|
55
55
|
describe file('Gemfile') do
|
56
56
|
it { should contain('rspec').after(/^group :test do/) }
|
57
|
-
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec /dev/stdin" }
|
57
|
+
its(:command) { should eq "sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -q -- rspec /dev/stdin || sed -n /\\^group\\ :test\\ do/,\\$p Gemfile | grep -qF -- rspec /dev/stdin" }
|
58
58
|
end
|
59
59
|
|
60
60
|
describe file('/etc/ssh/sshd_config') do
|
@@ -63,7 +63,7 @@ end
|
|
63
63
|
|
64
64
|
describe file('Gemfile') do
|
65
65
|
it { should contain('rspec').before(/^end/) }
|
66
|
-
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec /dev/stdin" }
|
66
|
+
its(:command) { should eq "sed -n 1,/\\^end/p Gemfile | grep -q -- rspec /dev/stdin || sed -n 1,/\\^end/p Gemfile | grep -qF -- rspec /dev/stdin" }
|
67
67
|
end
|
68
68
|
|
69
69
|
describe file('/etc/ssh/sshd_config') do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: serverspec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.11
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gosuke Miyashita
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-08-
|
11
|
+
date: 2013-08-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: net-ssh
|