jasmine 1.3.0 → 1.3.1
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +11 -2
- data/generators/jasmine/templates/spec/javascripts/support/jasmine-rails.yml +2 -2
- data/generators/jasmine/templates/spec/javascripts/support/jasmine.yml +2 -1
- data/jasmine.gemspec +1 -1
- data/lib/jasmine.rb +10 -2
- data/lib/jasmine/application.rb +6 -33
- data/lib/jasmine/asset_expander.rb +19 -0
- data/lib/jasmine/asset_pipeline_mapper.rb +11 -14
- data/lib/jasmine/asset_pipeline_utility.rb +19 -0
- data/lib/jasmine/base.rb +4 -0
- data/lib/jasmine/config.rb +74 -111
- data/lib/jasmine/configuration.rb +83 -0
- data/lib/jasmine/core_configuration.rb +28 -0
- data/lib/jasmine/javascripts/boot.js +28 -0
- data/lib/jasmine/path_expander.rb +18 -0
- data/lib/jasmine/path_mapper.rb +29 -0
- data/lib/jasmine/results_processor.rb +21 -20
- data/lib/jasmine/run.html.erb +0 -37
- data/lib/jasmine/run_specs.rb +12 -8
- data/lib/jasmine/server.rb +1 -1
- data/lib/jasmine/tasks/jasmine.rake +3 -4
- data/lib/jasmine/version.rb +1 -1
- data/lib/jasmine/yaml_config_parser.rb +54 -0
- data/spec/application_integration_spec.rb +15 -0
- data/spec/application_spec.rb +37 -92
- data/spec/asset_expander_spec.rb +42 -0
- data/spec/asset_pipeline_mapper_spec.rb +12 -11
- data/spec/base_spec.rb +14 -0
- data/spec/configuration_spec.rb +163 -0
- data/spec/jasmine_self_test_spec.rb +14 -7
- data/spec/page_spec.rb +2 -4
- data/spec/path_expander_spec.rb +96 -0
- data/spec/path_mapper_spec.rb +33 -0
- data/spec/server_spec.rb +2 -2
- data/spec/yaml_config_parser_spec.rb +182 -0
- metadata +34 -23
- data/lib/jasmine/runner_config.rb +0 -71
- data/lib/jasmine/sprockets_mapper.rb +0 -13
- data/lib/rack/jasmine/redirect.rb +0 -20
- data/spec/config_spec.rb +0 -309
- data/spec/fixture/jasmine.erb.yml +0 -4
- data/spec/fixture/spec/example_spec.js +0 -5
- data/spec/fixture/src/example.js +0 -3
- data/spec/jasmine_self_test_config.rb +0 -19
- data/spec/runner_config_spec.rb +0 -136
- data/spec/sprockets_mapper_spec.rb +0 -17
@@ -1,17 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
|
3
|
-
describe Jasmine::SprocketsMapper do
|
4
|
-
describe "mapping files" do
|
5
|
-
it "should retrieve asset paths from the the sprockets environment for passed files" do
|
6
|
-
src_files = ["assets/application.js", "assets/other_manifest.js"]
|
7
|
-
asset1 = double("asset1", :logical_path => "asset1.js")
|
8
|
-
asset2 = double("asset2", :logical_path => "asset2.js")
|
9
|
-
asset3 = double("asset3", :logical_path => "asset3.js")
|
10
|
-
asset_context = double("Sprockets::Environment")
|
11
|
-
asset_context.stub_chain(:find_asset).with("application").and_return([asset1, asset2])
|
12
|
-
asset_context.stub_chain(:find_asset).with("other_manifest").and_return([asset1, asset3])
|
13
|
-
mapper = Jasmine::SprocketsMapper.new(asset_context, 'some_location')
|
14
|
-
mapper.files(src_files).should == ['some_location/asset1.js?body=true', 'some_location/asset2.js?body=true', 'some_location/asset3.js?body=true']
|
15
|
-
end
|
16
|
-
end
|
17
|
-
end
|