Skip to content

Commit

Permalink
Fix spring binstub test
Browse files Browse the repository at this point in the history
Problem:

It appears that Spring has switched from using double-quotes in their
binstub to using single-quotes. The change has broken one of our tests,
where we are asserting that the binstub contains a line matching a
regular expression.

Solution:

Update the regular expression to use single-quotes, to match those
created by the binstub generator.
  • Loading branch information
c-lliope committed Nov 10, 2015
1 parent 664cc55 commit cbb95b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion spec/features/new_project_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@
it "adds spring to binstubs" do
expect(File).to exist("#{project_path}/bin/spring")

spring_line = /^ +load File.expand_path\("\.\.\/spring", __FILE__\)$/
spring_line = /^ +load File.expand_path\('\.\.\/spring', __FILE__\)$/
bin_stubs = %w(rake rails rspec)
bin_stubs.each do |bin_stub|
expect(IO.read("#{project_path}/bin/#{bin_stub}")).to match(spring_line)
Expand Down

0 comments on commit cbb95b6

Please sign in to comment.