We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4f3868a commit 14e8cdcCopy full SHA for 14e8cdc
spec/integration/ruby_command_line_spec.rb
@@ -150,5 +150,21 @@ class Dog
150
expect(out).to_not include("Could not find filename")
151
end
152
153
+
154
+ it "does not say 'syntax ok' when a syntax error fires" do
155
+ Dir.mktmpdir do |dir|
156
+ tmpdir = Pathname(dir)
157
+ script = tmpdir.join("script.rb")
158
+ script.write <<~'EOM'
159
+ break
160
+ EOM
161
162
+ out = `ruby -I#{lib_dir} -rsyntax_suggest -e "require_relative '#{script}'" 2>&1`
163
164
+ expect($?.success?).to be_falsey
165
+ expect(out.downcase).to_not include("syntax ok")
166
+ puts out
167
+ end
168
169
170
0 commit comments