Skip to content

Commit d0cd6d0

Browse files
committed
Merge pull request janl#137 from BigBlueHat/narrow_rspec_dependency
Narrow rspec dependency
2 parents 2ead28a + 577f7cc commit d0cd6d0

File tree

2 files changed

+13
-9
lines changed

2 files changed

+13
-9
lines changed

README.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -290,8 +290,10 @@ Or just install it as a RubyGem:
290290
## Plugins for jQuery, Dojo, Yui, CommonJS, qooxdoo
291291

292292
This repository lets you build modules for [jQuery][], [Dojo][], [Yui][] and
293-
[CommonJS][] / [Node.js][] with the help of `rake`. You may need to install
294-
rspec first by running `gem install rspec`.
293+
[CommonJS][] / [Node.js][] with the help of `rake`.
294+
295+
NOTE: The default `rake` task is only used for testing and require rspec to be
296+
installed (see below).
295297

296298
Run `rake jquery` to get a jQuery compatible plugin file in the
297299
`mustache-jquery/` directory.
@@ -309,6 +311,8 @@ Run `rake qooxdoo` to get a qooxdoo compatible file named `qooxdoo.mustache.js`.
309311

310312
## Testing
311313

314+
NOTE: You will need to install rspec first by running `gem install rspec`.
315+
312316
To run the mustache.js test suite, run `rake spec`. All specs will be run first with JavaScriptCore (using `jsc`)
313317
and again with Rhino, using `java org.mozilla.javascript.tools.shell.Main`.
314318

Rakefile

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
require 'rake'
2-
require 'rspec/core/rake_task'
32

43
task :default => :spec
54

6-
RSpec::Core::RakeTask.new(:spec) do |t|
7-
#t.spec_opts = ['--options', "\"#{File.dirname(__FILE__)}/spec/spec.opts\""]
8-
t.pattern = 'test/*_spec.rb'
9-
end
10-
115
desc "Run all specs"
12-
task :spec
6+
task :spec do
7+
require 'rspec/core/rake_task'
8+
RSpec::Core::RakeTask.new(:spec) do |t|
9+
#t.spec_opts = ['--options', "\"#{File.dirname(__FILE__)}/spec/spec.opts\""]
10+
t.pattern = 'test/*_spec.rb'
11+
end
12+
end
1313

1414
def templated_build(name, opts={})
1515
# Create a rule that uses the .tmpl.{pre,post} stuff to make a final,

0 commit comments

Comments
 (0)