forked from sumitngupta/jasmine-gem
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rails cleanup. Don't hard-fail on existence of jasmine.rake in Rails …
…3. Don't require entire Rails lib to load railtie. Remove unused files
- Loading branch information
Showing
6 changed files
with
25 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,9 @@ | ||
At the moment we don't have an automated way to test the Jasmine Gem in both configurations: Rails 2 / RSpec 1.x & Rails 3 / RSpec 2. CI will handle a broad matrix, but you need to ensure that your changes work across Rails 2&3. | ||
To test changes to the jasmine-gem: | ||
|
||
So here are the manual steps: | ||
|
||
* Edit jasmine.gemspec and uncomment the lines for Rails 2, comment out the lines for Rails 3 | ||
* Export RAILS_VERSION as either "pojs-rspec1", "pojs-rspec2", or "rails2" to test environments other than Rails 3. | ||
* Delete `Gemfile.lock` | ||
* Clear out your current gemset | ||
* exec a `bundle install` | ||
* `rake` until specs are green | ||
* Repeat with the Rails 3 development gems | ||
* Repeat again with the Rails 2 development gems | ||
* Repeat | ||
* Check in |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
require "rails/railtie" | ||
module Jasmine | ||
class Railtie < Rails::Railtie | ||
|
||
config.before_configuration do | ||
old_jasmine_rakefile = ::Rails.root.join('lib', 'tasks', 'jasmine.rake') | ||
if old_jasmine_rakefile.exist? && !ENV["USE_JASMINE_RAKE"] | ||
puts %Q{ | ||
You no longer need to have jasmine.rake in your project, as it is now automatically loaded | ||
from the Jasmine gem. To silence this warning, set "USE_JASMINE_RAKE=true" in your environment | ||
or remove jasmine.rake. | ||
} | ||
end | ||
end | ||
|
||
rake_tasks do | ||
load "jasmine/tasks/jasmine.rake" | ||
end | ||
end | ||
end |