Skip to content

Commit

Permalink
fix relative path issues with specs
Browse files Browse the repository at this point in the history
  • Loading branch information
justin808 committed Jan 24, 2016
1 parent dbd07e6 commit 5276607
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/generators/react_on_rails/dev_tests_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def change_package_json_to_use_local_react_on_rails_module
package_json = File.join(destination_root, "client", "package.json")
old_contents = File.read(package_json)
new_contents = old_contents.gsub(/"react-on-rails": ".+",/,
'"react-on-rails": "../../..",')
'"react-on-rails": "../../../..",')
File.open(package_json, "w+") { |f| f.puts new_contents }
end

Expand Down
2 changes: 1 addition & 1 deletion spec/react_on_rails/generators/dev_tests_generator_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

it "changes package.json to use local react-on-rails version of module" do
assert_file("client/package.json") do |contents|
assert_match('"react-on-rails": "../../.."', contents)
assert_match('"react-on-rails": "../../../.."', contents)
refute_match('"react-on-rails": "ReactOnRails::VERSION"', contents)
end
end
Expand Down

0 comments on commit 5276607

Please sign in to comment.