[ruby/syntax_suggest] Failing test for #157
https://github.com/ruby/syntax_suggest/commit/14e8cdc916
This commit is contained in:
parent
ee11090b28
commit
4d51a0b495
Notes:
git
2022-11-28 12:50:03 +00:00
@ -150,5 +150,21 @@ module SyntaxSuggest
|
||||
expect(out).to_not include("Could not find filename")
|
||||
end
|
||||
end
|
||||
|
||||
it "does not say 'syntax ok' when a syntax error fires" do
|
||||
Dir.mktmpdir do |dir|
|
||||
tmpdir = Pathname(dir)
|
||||
script = tmpdir.join("script.rb")
|
||||
script.write <<~'EOM'
|
||||
break
|
||||
EOM
|
||||
|
||||
out = `ruby -I#{lib_dir} -rsyntax_suggest -e "require_relative '#{script}'" 2>&1`
|
||||
|
||||
expect($?.success?).to be_falsey
|
||||
expect(out.downcase).to_not include("syntax ok")
|
||||
puts out
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user