upjs-rails 0.11.0 → 0.11.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +10 -1
- data/dist/up.js +138 -81
- data/dist/up.min.js +2 -2
- data/lib/assets/javascripts/up/boot.js.coffee +3 -0
- data/lib/assets/javascripts/up/browser.js.coffee +42 -26
- data/lib/assets/javascripts/up/flow.js.coffee +6 -4
- data/lib/assets/javascripts/up/history.js.coffee +1 -1
- data/lib/assets/javascripts/up/modal.js.coffee +4 -4
- data/lib/assets/javascripts/up/motion.js.coffee +6 -4
- data/lib/assets/javascripts/up/proxy.js.coffee +2 -1
- data/lib/assets/javascripts/up/util.js.coffee +61 -32
- data/lib/assets/javascripts/up.js.coffee +1 -10
- data/lib/upjs/rails/version.rb +1 -1
- data/spec_app/config/environments/development.rb +1 -1
- data/spec_app/spec/javascripts/helpers/reset_path.js.coffee +3 -2
- data/spec_app/spec/javascripts/up/flow_spec.js.coffee +1 -1
- data/spec_app/spec/javascripts/up/history_spec.js.coffee +53 -47
- data/spec_app/spec/javascripts/up/link_spec.js.coffee +1 -1
- data/spec_app/spec/javascripts/up/motion_spec.js.coffee +4 -4
- data/spec_app/spec/javascripts/up/proxy_spec.js.coffee +18 -9
- data/spec_app/vendor/assets/bower_components/jasmine/.bower.json +43 -7
- data/spec_app/vendor/assets/bower_components/jasmine/CONTRIBUTING.md +26 -17
- data/spec_app/vendor/assets/bower_components/jasmine/README.md +27 -18
- data/spec_app/vendor/assets/bower_components/jasmine/RELEASE.md +15 -5
- data/spec_app/vendor/assets/bower_components/jasmine/bower.json +41 -0
- data/spec_app/vendor/assets/bower_components/jasmine/lib/console/console.js +27 -3
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/boot.js +10 -9
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/example/node_example/{src → lib/jasmine_examples}/Player.js +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/example/node_example/{src → lib/jasmine_examples}/Song.js +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/jasmine-html.js +76 -20
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/jasmine.css +15 -18
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/jasmine.js +1399 -694
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/json2.js +73 -62
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/node_boot.js +1 -1
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core.js +29 -31
- data/spec_app/vendor/assets/bower_components/jasmine/package.json +18 -7
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/.bower.json +11 -13
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/MIT.LICENSE +1 -1
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/README.markdown +198 -125
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/bower.json +9 -10
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/lib/mock-ajax.js +250 -59
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/package.json +9 -4
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/release_notes/2.0.2.md +50 -0
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/release_notes/2.99.md +14 -0
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/release_notes/3.0.md +28 -0
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/release_notes/3.1.0.md +24 -0
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/release_notes/3.1.1.md +23 -0
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/release_notes/3.2.0.md +20 -0
- data/spec_app/vendor/assets/bower_components/jasmine-fixture/.bower.json +4 -4
- data/spec_app/vendor/assets/bower_components/jasmine-fixture/bower.json +1 -1
- data/spec_app/vendor/assets/bower_components/jasmine-fixture/dist/jasmine-fixture.js +4 -4
- data/spec_app/vendor/assets/bower_components/jasmine-fixture/dist/jasmine-fixture.min.js +2 -2
- data/spec_app/vendor/assets/bower_components/jasmine-jquery/.bower.json +4 -4
- data/spec_app/vendor/assets/bower_components/jasmine-jquery/Gruntfile.js +17 -1
- data/spec_app/vendor/assets/bower_components/jasmine-jquery/{MIT.LICENSE → LICENSE} +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine-jquery/README.md +14 -9
- data/spec_app/vendor/assets/bower_components/jasmine-jquery/bower.json +0 -1
- data/spec_app/vendor/assets/bower_components/jasmine-jquery/lib/jasmine-jquery.js +35 -10
- data/spec_app/vendor/assets/bower_components/jasmine-jquery/package.json +33 -24
- data/spec_app/vendor/assets/bower_components/jasmine-jquery/spec/fixtures/fixture_with_checkbox_with_checked.html +6 -0
- data/spec_app/vendor/assets/bower_components/jasmine-jquery/spec/suites/jasmine-jquery-spec.js +61 -1
- data/spec_app/vendor/assets/bower_components/jquery/.bower.json +5 -4
- data/spec_app/vendor/assets/bower_components/jquery/bower.json +2 -1
- data/spec_app/vendor/assets/bower_components/jquery/dist/jquery.js +9 -4
- data/spec_app/vendor/assets/bower_components/jquery/dist/jquery.min.js +4 -4
- data/spec_app/vendor/assets/bower_components/jquery/dist/jquery.min.map +1 -1
- data/spec_app/vendor/assets/bower_components/jquery/src/core.js +6 -1
- metadata +14 -175
- data/spec_app/vendor/assets/bower_components/jasmine/.gitignore +0 -24
- data/spec_app/vendor/assets/bower_components/jasmine/.gitmodules +0 -3
- data/spec_app/vendor/assets/bower_components/jasmine/.jshintrc +0 -9
- data/spec_app/vendor/assets/bower_components/jasmine/.npmignore +0 -21
- data/spec_app/vendor/assets/bower_components/jasmine/.rspec +0 -1
- data/spec_app/vendor/assets/bower_components/jasmine/.travis.yml +0 -51
- data/spec_app/vendor/assets/bower_components/jasmine/Gemfile +0 -12
- data/spec_app/vendor/assets/bower_components/jasmine/Gruntfile.js +0 -53
- data/spec_app/vendor/assets/bower_components/jasmine/Rakefile +0 -18
- data/spec_app/vendor/assets/bower_components/jasmine/dist/jasmine-standalone-1.0.0.zip +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/dist/jasmine-standalone-1.1.0.zip +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/dist/jasmine-standalone-1.2.0.zip +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/dist/jasmine-standalone-1.3.0.zip +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/dist/jasmine-standalone-1.3.1.zip +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/dist/jasmine-standalone-2.0.0.zip +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/dist/jasmine-standalone-2.0.1.zip +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/dist/jasmine-standalone-2.0.2.zip +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/dist/jasmine-standalone-2.0.3.zip +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/grunt/config/compass.js +0 -10
- data/spec_app/vendor/assets/bower_components/jasmine/grunt/config/compress.js +0 -66
- data/spec_app/vendor/assets/bower_components/jasmine/grunt/config/concat.js +0 -61
- data/spec_app/vendor/assets/bower_components/jasmine/grunt/config/jshint.js +0 -11
- data/spec_app/vendor/assets/bower_components/jasmine/grunt/tasks/build_standalone.js +0 -31
- data/spec_app/vendor/assets/bower_components/jasmine/grunt/tasks/version.js +0 -14
- data/spec_app/vendor/assets/bower_components/jasmine/grunt/templates/SpecRunner.html.jst +0 -26
- data/spec_app/vendor/assets/bower_components/jasmine/grunt/templates/licenseBanner.js.jst +0 -22
- data/spec_app/vendor/assets/bower_components/jasmine/grunt/templates/version.rb.jst +0 -9
- data/spec_app/vendor/assets/bower_components/jasmine/images/__init__.py +0 -0
- data/spec_app/vendor/assets/bower_components/jasmine/jasmine-core.gemspec +0 -23
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/__init__.py +0 -1
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/boot/boot.js +0 -120
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/boot/node_boot.js +0 -19
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/core.py +0 -60
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/example/node_example/spec/PlayerSpec.js +0 -60
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/example/node_example/spec/SpecHelper.js +0 -15
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/example/spec/PlayerSpec.js +0 -58
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/example/spec/SpecHelper.js +0 -15
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/example/src/Player.js +0 -22
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/example/src/Song.js +0 -7
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core/version.rb +0 -9
- data/spec_app/vendor/assets/bower_components/jasmine/lib/jasmine-core.rb +0 -53
- data/spec_app/vendor/assets/bower_components/jasmine/release_notes/2.0.1.md +0 -70
- data/spec_app/vendor/assets/bower_components/jasmine/release_notes/2.0.2.md +0 -25
- data/spec_app/vendor/assets/bower_components/jasmine/release_notes/20.md +0 -179
- data/spec_app/vendor/assets/bower_components/jasmine/setup.py +0 -47
- data/spec_app/vendor/assets/bower_components/jasmine/spec/console/ConsoleReporterSpec.js +0 -239
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/AnySpec.js +0 -46
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/CallTrackerSpec.js +0 -105
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/ClockSpec.js +0 -445
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/DelayedFunctionSchedulerSpec.js +0 -246
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/EnvSpec.js +0 -85
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/ExceptionFormatterSpec.js +0 -63
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/ExceptionsSpec.js +0 -68
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/ExpectationResultSpec.js +0 -61
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/ExpectationSpec.js +0 -427
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/JsApiReporterSpec.js +0 -214
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/MockDateSpec.js +0 -199
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/ObjectContainingSpec.js +0 -70
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/PrettyPrintSpec.js +0 -156
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/QueueRunnerSpec.js +0 -271
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/ReportDispatcherSpec.js +0 -40
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/SpecSpec.js +0 -260
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/SpySpec.js +0 -67
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/SpyStrategySpec.js +0 -111
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/SuiteSpec.js +0 -216
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/TimerSpec.js +0 -31
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/UtilSpec.js +0 -28
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/integration/CustomMatchersSpec.js +0 -149
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/integration/EnvSpec.js +0 -506
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/integration/SpecRunningSpec.js +0 -306
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/matchersUtilSpec.js +0 -239
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toBeCloseToSpec.js +0 -51
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toBeDefinedSpec.js +0 -18
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toBeFalsySpec.js +0 -38
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toBeGreaterThanSpec.js +0 -20
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toBeLessThanSpec.js +0 -20
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toBeNaNSpec.js +0 -37
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toBeNullSpec.js +0 -17
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toBeSpec.js +0 -17
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toBeTruthySpec.js +0 -38
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toBeUndefinedSpec.js +0 -18
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toContainSpec.js +0 -26
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toEqualSpec.js +0 -28
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toHaveBeenCalledSpec.js +0 -47
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toHaveBeenCalledWithSpec.js +0 -66
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toMatchSpec.js +0 -34
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toThrowErrorSpec.js +0 -280
- data/spec_app/vendor/assets/bower_components/jasmine/spec/core/matchers/toThrowSpec.js +0 -99
- data/spec_app/vendor/assets/bower_components/jasmine/spec/helpers/BrowserFlags.js +0 -23
- data/spec_app/vendor/assets/bower_components/jasmine/spec/helpers/defineJasmineUnderTest.js +0 -7
- data/spec_app/vendor/assets/bower_components/jasmine/spec/helpers/nodeDefineJasmineUnderTest.js +0 -33
- data/spec_app/vendor/assets/bower_components/jasmine/spec/html/HtmlReporterSpec.js +0 -616
- data/spec_app/vendor/assets/bower_components/jasmine/spec/html/HtmlSpecFilterSpec.js +0 -18
- data/spec_app/vendor/assets/bower_components/jasmine/spec/html/MatchersHtmlSpec.js +0 -37
- data/spec_app/vendor/assets/bower_components/jasmine/spec/html/PrettyPrintHtmlSpec.js +0 -15
- data/spec_app/vendor/assets/bower_components/jasmine/spec/html/QueryStringSpec.js +0 -43
- data/spec_app/vendor/assets/bower_components/jasmine/spec/html/ResultsNodeSpec.js +0 -62
- data/spec_app/vendor/assets/bower_components/jasmine/spec/javascripts/support/jasmine_selenium_runner.yml +0 -16
- data/spec_app/vendor/assets/bower_components/jasmine/spec/performance/large_object_test.js +0 -36
- data/spec_app/vendor/assets/bower_components/jasmine/spec/performance/performance_test.js +0 -10
- data/spec_app/vendor/assets/bower_components/jasmine/spec/support/jasmine-performance.json +0 -9
- data/spec_app/vendor/assets/bower_components/jasmine/spec/support/jasmine-performance.yml +0 -9
- data/spec_app/vendor/assets/bower_components/jasmine/spec/support/jasmine.json +0 -10
- data/spec_app/vendor/assets/bower_components/jasmine/spec/support/jasmine.yml +0 -25
- data/spec_app/vendor/assets/bower_components/jasmine/src/console/ConsoleReporter.js +0 -131
- data/spec_app/vendor/assets/bower_components/jasmine/src/console/requireConsole.js +0 -12
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/Any.js +0 -36
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js +0 -50
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/Clock.js +0 -113
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/DelayedFunctionScheduler.js +0 -145
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/Env.js +0 -341
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/ExceptionFormatter.js +0 -29
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/Expectation.js +0 -107
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/ExpectationResult.js +0 -45
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/JsApiReporter.js +0 -73
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/MockDate.js +0 -81
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/ObjectContaining.js +0 -34
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/PrettyPrinter.js +0 -137
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/QueueRunner.js +0 -92
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/ReportDispatcher.js +0 -35
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/Spec.js +0 -126
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/SpyStrategy.js +0 -51
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/Suite.js +0 -92
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/Timer.js +0 -22
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/base.js +0 -102
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/matchersUtil.js +0 -181
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/requireMatchers.js +0 -29
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toBe.js +0 -13
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toBeCloseTo.js +0 -18
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toBeDefined.js +0 -13
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toBeFalsy.js +0 -13
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toBeGreaterThan.js +0 -15
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toBeLessThan.js +0 -14
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toBeNaN.js +0 -22
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toBeNull.js +0 -14
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toBeTruthy.js +0 -14
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toBeUndefined.js +0 -14
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toContain.js +0 -16
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toEqual.js +0 -20
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toHaveBeenCalled.js +0 -28
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toHaveBeenCalledWith.js +0 -33
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toMatch.js +0 -16
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toThrow.js +0 -46
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/matchers/toThrowError.js +0 -156
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/requireCore.js +0 -39
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/requireInterface.js +0 -59
- data/spec_app/vendor/assets/bower_components/jasmine/src/core/util.js +0 -44
- data/spec_app/vendor/assets/bower_components/jasmine/src/html/HtmlReporter.js +0 -280
- data/spec_app/vendor/assets/bower_components/jasmine/src/html/HtmlSpecFilter.js +0 -12
- data/spec_app/vendor/assets/bower_components/jasmine/src/html/QueryString.js +0 -47
- data/spec_app/vendor/assets/bower_components/jasmine/src/html/ResultsNode.js +0 -19
- data/spec_app/vendor/assets/bower_components/jasmine/src/html/_HTMLReporter.scss +0 -355
- data/spec_app/vendor/assets/bower_components/jasmine/src/html/jasmine.scss +0 -1
- data/spec_app/vendor/assets/bower_components/jasmine/src/html/requireHtml.js +0 -6
- data/spec_app/vendor/assets/bower_components/jasmine/src/templates/example_project_jasmine_tags.html.erb +0 -3
- data/spec_app/vendor/assets/bower_components/jasmine/src/templates/version.js.erb +0 -7
- data/spec_app/vendor/assets/bower_components/jasmine/src/templates/version.rb.erb +0 -6
- data/spec_app/vendor/assets/bower_components/jasmine/src/version.js +0 -3
- data/spec_app/vendor/assets/bower_components/jasmine/travis-core-script.sh +0 -14
- data/spec_app/vendor/assets/bower_components/jasmine/travis-docs-script.sh +0 -5
- data/spec_app/vendor/assets/bower_components/jasmine/travis-node-script.sh +0 -6
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/Gruntfile.js +0 -63
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/src/boot.js +0 -11
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/src/fakeRequest.js +0 -262
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/src/mockAjax.js +0 -45
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/src/paramParser.js +0 -56
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/src/requestStub.js +0 -42
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/src/requestTracker.js +0 -51
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/src/requireAjax.js +0 -44
- data/spec_app/vendor/assets/bower_components/jasmine-ajax/src/stubTracker.js +0 -24
@@ -1,25 +0,0 @@
|
|
1
|
-
# Release Notes
|
2
|
-
|
3
|
-
## Summary
|
4
|
-
|
5
|
-
## Changes
|
6
|
-
|
7
|
-
* keep the files for running in a webpage around in the npm package
|
8
|
-
* Expose files and paths necessary to embed jasmine in an html page for nodejs
|
9
|
-
* Pull out the building of the jasmine interface so node and web both get the same one.
|
10
|
-
* Show a dot with color of pending spec when no expectations
|
11
|
-
* Console reporter prints out failed expectation's message
|
12
|
-
|
13
|
-
### Bugs
|
14
|
-
|
15
|
-
* Allow mocked Date constructor to be called with a subset of full params
|
16
|
-
|
17
|
-
## Pull Requests and Issues
|
18
|
-
|
19
|
-
* a disabled suite should call resultCallback with status being disabled
|
20
|
-
* disabled suite should still call onStart callback
|
21
|
-
|
22
|
-
|
23
|
-
------
|
24
|
-
|
25
|
-
_Release Notes generated with _[Anchorman](http://github.com/infews/anchorman)_
|
@@ -1,179 +0,0 @@
|
|
1
|
-
# Jasmine Core 2.0 Release Notes
|
2
|
-
|
3
|
-
## Summary
|
4
|
-
|
5
|
-
These notes are for Jasmine Core 2.0.
|
6
|
-
|
7
|
-
## Breaking Changes
|
8
|
-
|
9
|
-
The [`introduction.js`][intro] page covers the current syntax, highlighting the changes. Here are the known interface changes that are not backwards compatible with 1.x.
|
10
|
-
|
11
|
-
* New syntax for asynchronous specs
|
12
|
-
* New syntax for spies
|
13
|
-
* New interface for reporters
|
14
|
-
* Better Equality testing
|
15
|
-
* Replaced custom matchers for ease of use
|
16
|
-
* Change to `toThrow` matcher
|
17
|
-
* Clock now remains installed when a spec finishes
|
18
|
-
* More Jasmine internal variables/functions have been moved into closures
|
19
|
-
|
20
|
-
### New syntax for asynchronous specs
|
21
|
-
|
22
|
-
Similar to [Mocha][mocha], Jasmine `before`s, `spec`s, and `after`s can take an optional `done` callback in order to force asynchronous tests. The next function, whether it's a `before`, `spec` or `after`, will wait until this function is called or until a timeout is reached.
|
23
|
-
|
24
|
-
### New syntax for spies
|
25
|
-
|
26
|
-
Spies have a slightly modified syntax. The idea came from a desire to preserve any of the properties on a spied-upon function and some better testing patterns.
|
27
|
-
|
28
|
-
### New interface for reporters
|
29
|
-
|
30
|
-
The reporter interface has been **replaced**. The callbacks are different and more consistent. The objects passed in should only provide what is needed to report results. This enforces an interface to result data so custom reporters will be less coupled to the Jasmine implementation. The Jasmine reporter API now includes a slot for a `timer` object.
|
31
|
-
|
32
|
-
### Better Equality testing
|
33
|
-
|
34
|
-
We removed the previous equality code and are now using new code for testing equality. We started with [Underscore.js][underscore]'s `isEqual`, refactored a bit and added some additional tests.
|
35
|
-
|
36
|
-
### Replaced custom matchers for ease of use
|
37
|
-
|
38
|
-
The interface for adding custom matchers has been **replaced**. It has always been possible to add custom matchers, but the API was barely documented and difficult to test. We've changed how matchers are added and tested. Jasmine adds its own matchers by the same mechanism that custom matchers use. Dogfooding FTW.
|
39
|
-
|
40
|
-
### Change to `toThrow` matcher
|
41
|
-
|
42
|
-
We've changed the behavior of the `toThrow` matcher, moving some functionality to the `toThrowError` matcher. This should allow more of the requested use cases.
|
43
|
-
|
44
|
-
### Clock now remains installed when a spec finishes
|
45
|
-
|
46
|
-
After installing the Jasmine Clock, it will stay installed until `uninstall` is called -- clearing up any ambiguity for when those timing functions will revert to using the global clock object.
|
47
|
-
|
48
|
-
## More Jasmine internal variables/functions have been moved into closures
|
49
|
-
|
50
|
-
Certain variables/functions like a function to get the next spec id have been moved into closures, making the Jasmine interface cleaner.
|
51
|
-
|
52
|
-
## Other Changes
|
53
|
-
|
54
|
-
* Massive refactoring and better testing
|
55
|
-
* Environment setup now in `boot.js`
|
56
|
-
* Development and Build moved to Grunt
|
57
|
-
* Changes to how Jasmine is loaded
|
58
|
-
* Changes to how Jasmine is tested
|
59
|
-
* Better node.js support
|
60
|
-
* Better Continuous Integration Environment at Travis
|
61
|
-
* Support matrix updated
|
62
|
-
* Removed JsDoc Pages
|
63
|
-
* Adding Code Climate for JavaScript
|
64
|
-
|
65
|
-
## Massive refactoring and better testing
|
66
|
-
|
67
|
-
This is the biggest set of changes. We've touched nearly every file and every object. We've merged objects together and factored out code. We styled the code more consistently. We've improved nearly every test.
|
68
|
-
|
69
|
-
In general, Jasmine is made of smaller, more-loosely-coupled objects, unit-tested with explicit dependencies injected. This made tests easier to read, write, and maintain. We know this has made Jasmine development easier for the core team. We expect (and hope) this makes it easier for the community to extend Jasmine and provide pull requests that make more sense the first time out.
|
70
|
-
|
71
|
-
## Environment setup now in `boot.js`
|
72
|
-
|
73
|
-
Instantiation and setup of the Jasmine environment, including building reporters, exposing the "global" functions, and executing tests has moved into its own file: `boot.js`. This should make it easier to add custom reporters, configure some objects, or just in general change how you use Jasmine from the outside.
|
74
|
-
|
75
|
-
For example, during development, Jasmine uses its own `devboot.js` to load itself twice - once from `jasmine.js` and once from the source directories.
|
76
|
-
|
77
|
-
## Development and Build moved to Grunt
|
78
|
-
|
79
|
-
We've moved away from Ruby and embraced [Node.js][node] and [Grunt.js][grunt] for the various command line tasks during development. Yes, it's a just a different set of dependencies. But it's less code for the team to maintain - it turns out that JavaScript tools are pretty good at building JavaScript projects. This will make it easier for the community to make sure contributions work in browsers and in Node.js before submitting Pull Requests. There is more detail in the [Contributor's Guide][contrib].
|
80
|
-
|
81
|
-
## Changes to how Jasmine is loaded
|
82
|
-
|
83
|
-
We did not want to add new run-time dependencies, yet we needed to be cleaner when loading Jasmine. So we wrote a custom "require" scheme that works in Node.js and in browsers. This only affects pull requests which add files - please be careful in these cases. Again, the [Contributor's Guide][contrib] should help.
|
84
|
-
|
85
|
-
## Changes to how Jasmine is tested with Jasmine
|
86
|
-
|
87
|
-
Writing a custom require system helped enforce self-testing - the built `jasmine.js` testing Jasmine from the source directories. Overall this has improved the stability of the code. When you look at Jasmine's tests, you'll see both `jasmine` and `j$` used. The former, `jasmine`, will always be used to test the code from source, which is loaded into the reference `j$`. Please adhere to this pattern when writing tests for contributions.
|
88
|
-
|
89
|
-
## Better node.js support
|
90
|
-
|
91
|
-
`Node.js` is now officially a first-class citizen. For a long time we've made sure tests were green in Node before releasing. But it is now officially part of Jasmine's CI build at [Travis][travis]. For the curious, the [`node_suite.js`][node_suite], is essentially a `boot.js` for Node. An official `npm` is coming.
|
92
|
-
|
93
|
-
## Better Continuous Integration Environment at Travis
|
94
|
-
|
95
|
-
The [CI build at Travis][travis_jasmine] now runs the core specs in a build matrix across browsers. It's far from complete on the operating system matrix, but you will see that Jasmine runs against: Firefox, Chrome, Safari 5, Safari 6, [Phantom.js][phantom], [Node.js][node], and IE versions 8, 9, and 10. Big thanks to [SauceLabs][sauce] for their support of open source projects. We will happily take pull requests for additional OS/Browser combos within the matrix.
|
96
|
-
|
97
|
-
## Support Matrix Updated
|
98
|
-
|
99
|
-
We're dropping support for IE < 8. [Jasmine 1.x][jasmine_downloads] remains for projects that need to support older browsers.
|
100
|
-
|
101
|
-
## Removed JsDoc Pages
|
102
|
-
|
103
|
-
Comments in code are lies waiting to happen. Jasmine's JsDoc comments were no exception. The comments were out of date, the generated pages were even more out of date, and frankly they were not helpful. So they're gone.
|
104
|
-
|
105
|
-
Last year saw the posting of the [`introduction.js`][intro] page to document the real, practical interface for projects to use. This page has received a lot of positive feedback so expect more pages like this one.
|
106
|
-
|
107
|
-
## Adding Code Climate for JavaScript
|
108
|
-
|
109
|
-
We are running Code Climate for Jasmine. We have some work to do here but it's helping us easily find code hotspots.
|
110
|
-
|
111
|
-
## Pull Requests and Issues
|
112
|
-
|
113
|
-
The following Pull Requests were merged:
|
114
|
-
|
115
|
-
* ObjectContaining wrong filed value error message #[394](https://github.com/pivotal/jasmine/issues/394) from albertandrejev
|
116
|
-
* Removed unnecessary parameter from `suiteFactory()` call #[397](https://github.com/pivotal/jasmine/issues/397) from valera-rozuvan
|
117
|
-
* `jasmine.Any` supports `Boolean` #[392](https://github.com/pivotal/jasmine/issues/392) from albertandrejev
|
118
|
-
* Reporters get execution time #[30](https://github.com/pivotal/jasmine/issues/30)
|
119
|
-
* `toThrow` matchers handle falsy exceptions #[317](https://github.com/pivotal/jasmine/issues/371)
|
120
|
-
* Removed deprecated `jasmine.Matchers.pp` #[363](https://github.com/pivotal/jasmine/issues/363) from robinboehm
|
121
|
-
* Fix for Clock ticking to default to 0 #[340](https://github.com/pivotal/jasmine/issues/340) from Caio Cunha
|
122
|
-
* Whitespace failures should be easier to understand #[332](https://github.com/pivotal/jasmine/issues/332) from bjornblomqvist
|
123
|
-
* Fix for more markdown-y image for Build status #[329](https://github.com/pivotal/jasmine/issues/329) from sunliwen
|
124
|
-
* UTF-8 encoding fixes #[333](https://github.com/pivotal/jasmine/issues/333) from bjornblomqvist
|
125
|
-
* Replaced deprecated octal literal with hexadecimal from kris7t
|
126
|
-
* Make getGlobal() work in strict mode from metaweta
|
127
|
-
* Clears timeout timer even when async spec throws an exception from tidoust
|
128
|
-
* Timeouts scheduled within a delayed function are correctly scheduled and executed from maciej-filip-sz
|
129
|
-
|
130
|
-
### Bug Fixes
|
131
|
-
* Improved the performance of the HTML output with a CSS change #[428](https://github.com/pivotal/jasmine/issues/428) - Thanks @tjgrathwell
|
132
|
-
* Removed an accidental global pollution of `j$` as a reference to Jasmine. Thanks to Morten Maxild from the mailing list
|
133
|
-
* There is now a consistent `this` between `beforeEach`, `it` and `afterEach` for a spec
|
134
|
-
* A spy's strategy now has properties `returnValue` and `throwError` because they are better names
|
135
|
-
* Make it easy to copy the title of failing specs from the HTML output
|
136
|
-
* Don't add periods to the full name of a spec fix #[427](https://github.com/pivotal/jasmine/issues/427)
|
137
|
-
* Allow Env to take optional spec/suite ids when asked to `execute`
|
138
|
-
* [Mock clock now less intrusive, replacing global timer functions only when clock is installed](http://www.pivotaltracker.com/story/54168708)
|
139
|
-
* Restore custom failure messages for `toHaveBeenCalledWith`
|
140
|
-
* Jasmine global object has a addCustomEqualityTester and addMatchers (no longer directly on global)
|
141
|
-
* Fixed a global leak of `timer`
|
142
|
-
* Remove currentRunner from Env (users can use topSuite from Env instead)
|
143
|
-
* [Specs without expectations are now considered passing](http://www.pivotaltracker.com/story/59422744)
|
144
|
-
* Improve error message when a spec does not call the async callback within the default time interval
|
145
|
-
* Allow passing a negativeCompare in a custom matcher for more custom implementations when `.not` is called
|
146
|
-
* Update favicon to be higher resolution
|
147
|
-
* Make all async functions be subject to the timeout
|
148
|
-
|
149
|
-
There were several other pull requests that either had already been fixed, or were good starting points for the various changes above. Thank you for all of the hard work to keep Jasmine awesome.
|
150
|
-
|
151
|
-
## Other Bugs and Features
|
152
|
-
|
153
|
-
There were a few small changes and fixes that didn't fit into any of the above categories:
|
154
|
-
|
155
|
-
* HTML Reporter refactored for simplicity and performance
|
156
|
-
* Default character encoding on the HTML runner page is UTF-8
|
157
|
-
* [Escape special regex characters from the spec param](http://www.pivotaltracker.com/story/52731407)
|
158
|
-
* Favicon returns
|
159
|
-
* [Clock supports `eval`'d strings as functions](http://www.pivotaltracker.com/story/40853563)
|
160
|
-
* There should always be stack traces on failures
|
161
|
-
* Removed references to unused `jasmine.VERBOSE`
|
162
|
-
* Removed references to unused `jasmine.XmlHttpRequest`
|
163
|
-
|
164
|
-
[mocha]: http://visionmedia.github.io/mocha/
|
165
|
-
[underscore]: http://underscorejs.org/
|
166
|
-
[grunt]: http://gruntjs.com
|
167
|
-
[node]: http://nodejs.org
|
168
|
-
[phantom]: http://phantomjs.org
|
169
|
-
[jasmine_downloads]: https://github.com/pivotal/jasmine/downloads
|
170
|
-
[contrib]: https://github.com/pivotal/jasmine/blob/master/CONTRIBUTING.md
|
171
|
-
[travis]: http://travis-ci.org
|
172
|
-
[travis_jasmine]: http://travis-ci.org/jasmine
|
173
|
-
[sauce]: http://saucelabs.com
|
174
|
-
[node_suite]: https://github.com/pivotal/jasmine/blob/master/spec/node_suite.js
|
175
|
-
[intro]: http://jasmine.github.io/2.0/introduction.html
|
176
|
-
|
177
|
-
------
|
178
|
-
|
179
|
-
_Release Notes generated with [Anchorman](http://github.com/infews/anchorman)_
|
@@ -1,47 +0,0 @@
|
|
1
|
-
from setuptools import setup, find_packages, os
|
2
|
-
import json
|
3
|
-
|
4
|
-
with open('package.json') as packageFile:
|
5
|
-
version = json.load(packageFile)['version']
|
6
|
-
|
7
|
-
setup(
|
8
|
-
name="jasmine-core",
|
9
|
-
version=version,
|
10
|
-
url="http://pivotal.github.io/jasmine/",
|
11
|
-
author="Pivotal Labs",
|
12
|
-
author_email="jasmine-js@googlegroups.com",
|
13
|
-
description=('Jasmine is a Behavior Driven Development testing framework for JavaScript. It does not rely on '+
|
14
|
-
'browsers, DOM, or any JavaScript framework. Thus it\'s suited for websites, '+
|
15
|
-
'Node.js (http://nodejs.org) projects, or anywhere that JavaScript can run.'),
|
16
|
-
license='MIT',
|
17
|
-
classifiers=[
|
18
|
-
'Development Status :: 5 - Production/Stable',
|
19
|
-
'Environment :: Console',
|
20
|
-
'Environment :: Web Environment',
|
21
|
-
'Framework :: Django',
|
22
|
-
'Intended Audience :: Developers',
|
23
|
-
'License :: OSI Approved :: MIT License',
|
24
|
-
'Operating System :: OS Independent',
|
25
|
-
'Programming Language :: Python',
|
26
|
-
'Programming Language :: Python :: 2',
|
27
|
-
'Programming Language :: Python :: 2.6',
|
28
|
-
'Programming Language :: Python :: 2.7',
|
29
|
-
'Programming Language :: Python :: 3',
|
30
|
-
'Programming Language :: Python :: 3.2',
|
31
|
-
'Programming Language :: Python :: 3.3',
|
32
|
-
'Programming Language :: Python :: Implementation :: PyPy',
|
33
|
-
'Topic :: Internet :: WWW/HTTP',
|
34
|
-
'Topic :: Software Development :: Libraries :: Python Modules',
|
35
|
-
'Topic :: Software Development :: Build Tools',
|
36
|
-
'Topic :: Software Development :: Quality Assurance',
|
37
|
-
'Topic :: Software Development :: Testing',
|
38
|
-
],
|
39
|
-
|
40
|
-
packages=['jasmine_core', 'jasmine_core.images'],
|
41
|
-
package_dir={'jasmine_core': 'lib/jasmine-core', 'jasmine_core.images': 'images'},
|
42
|
-
package_data={'jasmine_core': ['*.js', '*.css'], 'jasmine_core.images': ['*.png']},
|
43
|
-
|
44
|
-
include_package_data=True,
|
45
|
-
|
46
|
-
install_requires=['glob2>=0.4.1', 'ordereddict==1.1']
|
47
|
-
)
|
@@ -1,239 +0,0 @@
|
|
1
|
-
describe("ConsoleReporter", function() {
|
2
|
-
var out;
|
3
|
-
|
4
|
-
beforeEach(function() {
|
5
|
-
out = (function() {
|
6
|
-
var output = "";
|
7
|
-
return {
|
8
|
-
print: function(str) {
|
9
|
-
output += str;
|
10
|
-
},
|
11
|
-
getOutput: function() {
|
12
|
-
return output;
|
13
|
-
},
|
14
|
-
clear: function() {
|
15
|
-
output = "";
|
16
|
-
}
|
17
|
-
};
|
18
|
-
}());
|
19
|
-
});
|
20
|
-
|
21
|
-
it("reports that the suite has started to the console", function() {
|
22
|
-
var reporter = new j$.ConsoleReporter({
|
23
|
-
print: out.print
|
24
|
-
});
|
25
|
-
|
26
|
-
reporter.jasmineStarted();
|
27
|
-
|
28
|
-
expect(out.getOutput()).toEqual("Started\n");
|
29
|
-
});
|
30
|
-
|
31
|
-
it("starts the provided timer when jasmine starts", function() {
|
32
|
-
var timerSpy = jasmine.createSpyObj('timer', ['start']),
|
33
|
-
reporter = new j$.ConsoleReporter({
|
34
|
-
print: out.print,
|
35
|
-
timer: timerSpy
|
36
|
-
});
|
37
|
-
|
38
|
-
reporter.jasmineStarted();
|
39
|
-
|
40
|
-
expect(timerSpy.start).toHaveBeenCalled();
|
41
|
-
});
|
42
|
-
|
43
|
-
it("reports a passing spec as a dot", function() {
|
44
|
-
var reporter = new j$.ConsoleReporter({
|
45
|
-
print: out.print
|
46
|
-
});
|
47
|
-
|
48
|
-
reporter.specDone({status: "passed"});
|
49
|
-
|
50
|
-
expect(out.getOutput()).toEqual(".");
|
51
|
-
});
|
52
|
-
|
53
|
-
it("does not report a disabled spec", function() {
|
54
|
-
var reporter = new j$.ConsoleReporter({
|
55
|
-
print: out.print
|
56
|
-
});
|
57
|
-
|
58
|
-
reporter.specDone({status: "disabled"});
|
59
|
-
|
60
|
-
expect(out.getOutput()).toEqual("");
|
61
|
-
});
|
62
|
-
|
63
|
-
it("reports a failing spec as an 'F'", function() {
|
64
|
-
var reporter = new j$.ConsoleReporter({
|
65
|
-
print: out.print
|
66
|
-
});
|
67
|
-
|
68
|
-
reporter.specDone({status: "failed"});
|
69
|
-
|
70
|
-
expect(out.getOutput()).toEqual("F");
|
71
|
-
});
|
72
|
-
|
73
|
-
it("reports a pending spec as a '*'", function() {
|
74
|
-
var reporter = new j$.ConsoleReporter({
|
75
|
-
print: out.print
|
76
|
-
});
|
77
|
-
|
78
|
-
reporter.specDone({status: "pending"});
|
79
|
-
|
80
|
-
expect(out.getOutput()).toEqual("*");
|
81
|
-
});
|
82
|
-
|
83
|
-
it("alerts user if there are no specs", function(){
|
84
|
-
var reporter = new j$.ConsoleReporter({
|
85
|
-
print: out.print
|
86
|
-
});
|
87
|
-
|
88
|
-
reporter.jasmineStarted();
|
89
|
-
out.clear();
|
90
|
-
reporter.jasmineDone();
|
91
|
-
|
92
|
-
expect(out.getOutput()).toMatch(/No specs found/);
|
93
|
-
});
|
94
|
-
|
95
|
-
it("reports a summary when done (singular spec and time)", function() {
|
96
|
-
var timerSpy = jasmine.createSpyObj('timer', ['start', 'elapsed']),
|
97
|
-
reporter = new j$.ConsoleReporter({
|
98
|
-
print: out.print,
|
99
|
-
timer: timerSpy
|
100
|
-
});
|
101
|
-
|
102
|
-
reporter.jasmineStarted();
|
103
|
-
reporter.specDone({status: "passed"});
|
104
|
-
|
105
|
-
timerSpy.elapsed.and.returnValue(1000);
|
106
|
-
|
107
|
-
out.clear();
|
108
|
-
reporter.jasmineDone();
|
109
|
-
|
110
|
-
expect(out.getOutput()).toMatch(/1 spec, 0 failures/);
|
111
|
-
expect(out.getOutput()).not.toMatch(/0 pending specs/);
|
112
|
-
expect(out.getOutput()).toMatch("Finished in 1 second\n");
|
113
|
-
});
|
114
|
-
|
115
|
-
it("reports a summary when done (pluralized specs and seconds)", function() {
|
116
|
-
var timerSpy = jasmine.createSpyObj('timer', ['start', 'elapsed']),
|
117
|
-
reporter = new j$.ConsoleReporter({
|
118
|
-
print: out.print,
|
119
|
-
timer: timerSpy
|
120
|
-
});
|
121
|
-
|
122
|
-
reporter.jasmineStarted();
|
123
|
-
reporter.specDone({status: "passed"});
|
124
|
-
reporter.specDone({status: "pending"});
|
125
|
-
reporter.specDone({
|
126
|
-
status: "failed",
|
127
|
-
description: "with a failing spec",
|
128
|
-
fullName: "A suite with a failing spec",
|
129
|
-
failedExpectations: [
|
130
|
-
{
|
131
|
-
passed: false,
|
132
|
-
message: "Expected true to be false.",
|
133
|
-
expected: false,
|
134
|
-
actual: true,
|
135
|
-
stack: "foo\nbar\nbaz"
|
136
|
-
}
|
137
|
-
]
|
138
|
-
});
|
139
|
-
|
140
|
-
out.clear();
|
141
|
-
|
142
|
-
timerSpy.elapsed.and.returnValue(100);
|
143
|
-
|
144
|
-
reporter.jasmineDone();
|
145
|
-
|
146
|
-
expect(out.getOutput()).toMatch(/3 specs, 1 failure, 1 pending spec/);
|
147
|
-
expect(out.getOutput()).toMatch("Finished in 0.1 seconds\n");
|
148
|
-
});
|
149
|
-
|
150
|
-
it("reports a summary when done that includes stack traces for a failing suite", function() {
|
151
|
-
var reporter = new j$.ConsoleReporter({
|
152
|
-
print: out.print
|
153
|
-
});
|
154
|
-
|
155
|
-
reporter.jasmineStarted();
|
156
|
-
reporter.specDone({status: "passed"});
|
157
|
-
reporter.specDone({
|
158
|
-
status: "failed",
|
159
|
-
description: "with a failing spec",
|
160
|
-
fullName: "A suite with a failing spec",
|
161
|
-
failedExpectations: [
|
162
|
-
{
|
163
|
-
passed: false,
|
164
|
-
message: "Expected true to be false.",
|
165
|
-
expected: false,
|
166
|
-
actual: true,
|
167
|
-
stack: "foo bar baz"
|
168
|
-
}
|
169
|
-
]
|
170
|
-
});
|
171
|
-
|
172
|
-
out.clear();
|
173
|
-
|
174
|
-
reporter.jasmineDone({});
|
175
|
-
|
176
|
-
expect(out.getOutput()).toMatch(/true to be false/);
|
177
|
-
expect(out.getOutput()).toMatch(/foo bar baz/);
|
178
|
-
});
|
179
|
-
|
180
|
-
it("calls the onComplete callback when the suite is done", function() {
|
181
|
-
var onComplete = jasmine.createSpy('onComplete'),
|
182
|
-
reporter = new j$.ConsoleReporter({
|
183
|
-
print: out.print,
|
184
|
-
onComplete: onComplete
|
185
|
-
});
|
186
|
-
|
187
|
-
reporter.jasmineDone({});
|
188
|
-
|
189
|
-
expect(onComplete).toHaveBeenCalled();
|
190
|
-
});
|
191
|
-
|
192
|
-
|
193
|
-
describe("with color", function() {
|
194
|
-
|
195
|
-
it("reports that the suite has started to the console", function() {
|
196
|
-
var reporter = new j$.ConsoleReporter({
|
197
|
-
print: out.print,
|
198
|
-
showColors: true
|
199
|
-
});
|
200
|
-
|
201
|
-
reporter.jasmineStarted();
|
202
|
-
|
203
|
-
expect(out.getOutput()).toEqual("Started\n");
|
204
|
-
});
|
205
|
-
|
206
|
-
it("reports a passing spec as a dot", function() {
|
207
|
-
var reporter = new j$.ConsoleReporter({
|
208
|
-
print: out.print,
|
209
|
-
showColors: true
|
210
|
-
});
|
211
|
-
|
212
|
-
reporter.specDone({status: "passed"});
|
213
|
-
|
214
|
-
expect(out.getOutput()).toEqual("\x1B[32m.\x1B[0m");
|
215
|
-
});
|
216
|
-
|
217
|
-
it("does not report a disabled spec", function() {
|
218
|
-
var reporter = new j$.ConsoleReporter({
|
219
|
-
print: out.print,
|
220
|
-
showColors: true
|
221
|
-
});
|
222
|
-
|
223
|
-
reporter.specDone({status: 'disabled'});
|
224
|
-
|
225
|
-
expect(out.getOutput()).toEqual("");
|
226
|
-
});
|
227
|
-
|
228
|
-
it("reports a failing spec as an 'F'", function() {
|
229
|
-
var reporter = new j$.ConsoleReporter({
|
230
|
-
print: out.print,
|
231
|
-
showColors: true
|
232
|
-
});
|
233
|
-
|
234
|
-
reporter.specDone({status: 'failed'});
|
235
|
-
|
236
|
-
expect(out.getOutput()).toEqual("\x1B[31mF\x1B[0m");
|
237
|
-
});
|
238
|
-
});
|
239
|
-
});
|
@@ -1,46 +0,0 @@
|
|
1
|
-
describe("Any", function() {
|
2
|
-
it("matches a string", function() {
|
3
|
-
var any = new j$.Any(String);
|
4
|
-
|
5
|
-
expect(any.jasmineMatches("foo")).toBe(true);
|
6
|
-
});
|
7
|
-
|
8
|
-
it("matches a number", function() {
|
9
|
-
var any = new j$.Any(Number);
|
10
|
-
|
11
|
-
expect(any.jasmineMatches(1)).toBe(true);
|
12
|
-
});
|
13
|
-
|
14
|
-
it("matches a function", function() {
|
15
|
-
var any = new j$.Any(Function);
|
16
|
-
|
17
|
-
expect(any.jasmineMatches(function(){})).toBe(true);
|
18
|
-
});
|
19
|
-
|
20
|
-
it("matches an Object", function() {
|
21
|
-
var any = new j$.Any(Object);
|
22
|
-
|
23
|
-
expect(any.jasmineMatches({})).toBe(true);
|
24
|
-
});
|
25
|
-
|
26
|
-
it("matches a Boolean", function() {
|
27
|
-
var any = new j$.Any(Boolean);
|
28
|
-
|
29
|
-
expect(any.jasmineMatches(true)).toBe(true);
|
30
|
-
});
|
31
|
-
|
32
|
-
it("matches another constructed object", function() {
|
33
|
-
var Thing = function() {},
|
34
|
-
any = new j$.Any(Thing);
|
35
|
-
|
36
|
-
expect(any.jasmineMatches(new Thing())).toBe(true);
|
37
|
-
});
|
38
|
-
|
39
|
-
it("jasmineToString's itself", function() {
|
40
|
-
var any = new j$.Any(Number);
|
41
|
-
|
42
|
-
expect(any.jasmineToString()).toMatch('<jasmine.any');
|
43
|
-
expect(any.jasmineToString()).toMatch('Number');
|
44
|
-
});
|
45
|
-
|
46
|
-
});
|
@@ -1,105 +0,0 @@
|
|
1
|
-
describe("CallTracker", function() {
|
2
|
-
it("tracks that it was called when executed", function() {
|
3
|
-
var callTracker = new j$.CallTracker();
|
4
|
-
|
5
|
-
expect(callTracker.any()).toBe(false);
|
6
|
-
|
7
|
-
callTracker.track();
|
8
|
-
|
9
|
-
expect(callTracker.any()).toBe(true);
|
10
|
-
});
|
11
|
-
|
12
|
-
it("tracks that number of times that it is executed", function() {
|
13
|
-
var callTracker = new j$.CallTracker();
|
14
|
-
|
15
|
-
expect(callTracker.count()).toEqual(0);
|
16
|
-
|
17
|
-
callTracker.track();
|
18
|
-
|
19
|
-
expect(callTracker.count()).toEqual(1);
|
20
|
-
});
|
21
|
-
|
22
|
-
it("tracks the params from each execution", function() {
|
23
|
-
var callTracker = new j$.CallTracker();
|
24
|
-
|
25
|
-
callTracker.track({object: void 0, args: []});
|
26
|
-
callTracker.track({object: {}, args: [0, "foo"]});
|
27
|
-
|
28
|
-
expect(callTracker.argsFor(0)).toEqual([]);
|
29
|
-
|
30
|
-
expect(callTracker.argsFor(1)).toEqual([0, "foo"]);
|
31
|
-
});
|
32
|
-
|
33
|
-
it("returns any empty array when there was no call", function() {
|
34
|
-
var callTracker = new j$.CallTracker();
|
35
|
-
|
36
|
-
expect(callTracker.argsFor(0)).toEqual([]);
|
37
|
-
});
|
38
|
-
|
39
|
-
it("allows access for the arguments for all calls", function() {
|
40
|
-
var callTracker = new j$.CallTracker();
|
41
|
-
|
42
|
-
callTracker.track({object: {}, args: []});
|
43
|
-
callTracker.track({object: {}, args: [0, "foo"]});
|
44
|
-
|
45
|
-
expect(callTracker.allArgs()).toEqual([[], [0, "foo"]]);
|
46
|
-
});
|
47
|
-
|
48
|
-
it("tracks the context and arguments for each call", function() {
|
49
|
-
var callTracker = new j$.CallTracker();
|
50
|
-
|
51
|
-
callTracker.track({object: {}, args: []});
|
52
|
-
callTracker.track({object: {}, args: [0, "foo"]});
|
53
|
-
|
54
|
-
expect(callTracker.all()[0]).toEqual({object: {}, args: []});
|
55
|
-
|
56
|
-
expect(callTracker.all()[1]).toEqual({object: {}, args: [0, "foo"]});
|
57
|
-
});
|
58
|
-
|
59
|
-
it("simplifies access to the arguments for the last (most recent) call", function() {
|
60
|
-
var callTracker = new j$.CallTracker();
|
61
|
-
|
62
|
-
callTracker.track();
|
63
|
-
callTracker.track({object: {}, args: [0, "foo"]});
|
64
|
-
|
65
|
-
expect(callTracker.mostRecent()).toEqual({
|
66
|
-
object: {},
|
67
|
-
args: [0, "foo"]
|
68
|
-
});
|
69
|
-
});
|
70
|
-
|
71
|
-
it("returns a useful falsy value when there isn't a last (most recent) call", function() {
|
72
|
-
var callTracker = new j$.CallTracker();
|
73
|
-
|
74
|
-
expect(callTracker.mostRecent()).toBeFalsy();
|
75
|
-
});
|
76
|
-
|
77
|
-
it("simplifies access to the arguments for the first (oldest) call", function() {
|
78
|
-
var callTracker = new j$.CallTracker();
|
79
|
-
|
80
|
-
callTracker.track({object: {}, args: [0, "foo"]});
|
81
|
-
|
82
|
-
expect(callTracker.first()).toEqual({object: {}, args: [0, "foo"]})
|
83
|
-
});
|
84
|
-
|
85
|
-
it("returns a useful falsy value when there isn't a first (oldest) call", function() {
|
86
|
-
var callTracker = new j$.CallTracker();
|
87
|
-
|
88
|
-
expect(callTracker.first()).toBeFalsy();
|
89
|
-
});
|
90
|
-
|
91
|
-
|
92
|
-
it("allows the tracking to be reset", function() {
|
93
|
-
var callTracker = new j$.CallTracker();
|
94
|
-
|
95
|
-
callTracker.track();
|
96
|
-
callTracker.track({object: {}, args: [0, "foo"]});
|
97
|
-
callTracker.reset();
|
98
|
-
|
99
|
-
expect(callTracker.any()).toBe(false);
|
100
|
-
expect(callTracker.count()).toEqual(0);
|
101
|
-
expect(callTracker.argsFor(0)).toEqual([]);
|
102
|
-
expect(callTracker.all()).toEqual([]);
|
103
|
-
expect(callTracker.mostRecent()).toBeFalsy();
|
104
|
-
});
|
105
|
-
});
|