Skip to content

Commit

Permalink
Fix dummy Rails 5 for test
Browse files Browse the repository at this point in the history
  • Loading branch information
BookOfGreg committed Jul 1, 2016
1 parent 85f1297 commit a63934e
Show file tree
Hide file tree
Showing 8 changed files with 10 additions and 48 deletions.
2 changes: 1 addition & 1 deletion codemirror-rails.gemspec
Expand Up @@ -12,7 +12,7 @@ Gem::Specification.new do |s|

s.files = `git ls-files`.split("\n")

s.add_runtime_dependency 'railties', '>= 3.0', '< 5.1'
s.add_runtime_dependency 'railties', '>= 3.0', '< 6.0'

s.add_development_dependency 'rails'
s.add_development_dependency 'sqlite3'
Expand Down
7 changes: 1 addition & 6 deletions test/dummy-5.0.x/bin/rails
@@ -1,9 +1,4 @@
#!/usr/bin/env ruby
begin
load File.expand_path('../spring', __FILE__)
rescue LoadError => e
raise unless e.message.include?('spring')
end
APP_PATH = File.expand_path('../config/application', __dir__)
APP_PATH = File.expand_path('../../config/application', __FILE__)
require_relative '../config/boot'
require 'rails/commands'
5 changes: 0 additions & 5 deletions test/dummy-5.0.x/bin/rake
@@ -1,9 +1,4 @@
#!/usr/bin/env ruby
begin
load File.expand_path('../spring', __FILE__)
rescue LoadError => e
raise unless e.message.include?('spring')
end
require_relative '../config/boot'
require 'rake'
Rake.application.run
34 changes: 0 additions & 34 deletions test/dummy-5.0.x/bin/setup

This file was deleted.

4 changes: 4 additions & 0 deletions test/dummy-5.0.x/config.ru
@@ -0,0 +1,4 @@
# This file is used by Rack-based servers to start the application.

require ::File.expand_path('../config/environment', __FILE__)
run Rails.application
1 change: 1 addition & 0 deletions test/dummy-5.0.x/config/application.rb
Expand Up @@ -5,6 +5,7 @@
# Require the gems listed in Gemfile, including any gems
# you've limited to :test, :development, or :production.
Bundler.require(*Rails.groups)
require "codemirror-rails"

module Dummy
class Application < Rails::Application
Expand Down
3 changes: 2 additions & 1 deletion test/dummy-5.0.x/config/boot.rb
@@ -1,3 +1,4 @@
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../Gemfile', __dir__)
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../../../Gemfile', __FILE__)

require 'bundler/setup' # Set up gems listed in the Gemfile.
$LOAD_PATH.unshift File.expand_path('../../../../lib', __FILE__)
2 changes: 1 addition & 1 deletion test/dummy-5.0.x/config/environments/development.rb
Expand Up @@ -50,5 +50,5 @@

# Use an evented file watcher to asynchronously detect changes in source code,
# routes, locales, etc. This feature depends on the listen gem.
config.file_watcher = ActiveSupport::EventedFileUpdateChecker
# config.file_watcher = ActiveSupport::EventedFileUpdateChecker
end

0 comments on commit a63934e

Please sign in to comment.