From e5cb549da581a65cd57f382f5740a988ff79085a Mon Sep 17 00:00:00 2001 From: mo khan Date: Fri, 26 Jul 2013 22:12:07 -0600 Subject: install teaspoon --- spec/javascripts/helpers/.gitkeep | 0 spec/javascripts/helpers/SpecHelper.js | 9 --------- spec/javascripts/spec_helper.js | 26 ++++++++++++++++++++++++++ 3 files changed, 26 insertions(+), 9 deletions(-) delete mode 100644 spec/javascripts/helpers/.gitkeep delete mode 100644 spec/javascripts/helpers/SpecHelper.js create mode 100644 spec/javascripts/spec_helper.js (limited to 'spec/javascripts') diff --git a/spec/javascripts/helpers/.gitkeep b/spec/javascripts/helpers/.gitkeep deleted file mode 100644 index e69de29b..00000000 diff --git a/spec/javascripts/helpers/SpecHelper.js b/spec/javascripts/helpers/SpecHelper.js deleted file mode 100644 index 4919c87a..00000000 --- a/spec/javascripts/helpers/SpecHelper.js +++ /dev/null @@ -1,9 +0,0 @@ -beforeEach(function() { - this.addMatchers({ - toBePlaying: function(expectedSong) { - var player = this.actual; - return player.currentlyPlayingSong === expectedSong - && player.isPlaying; - } - }) -}); diff --git a/spec/javascripts/spec_helper.js b/spec/javascripts/spec_helper.js new file mode 100644 index 00000000..24b88290 --- /dev/null +++ b/spec/javascripts/spec_helper.js @@ -0,0 +1,26 @@ +// Teaspoon includes some support files, but you can use anything from your own support path too. +// require support/jasmine-jquery +// require support/sinon +// require support/your-support-file +// +// Deferring execution +// If you're using CommonJS, RequireJS or some other asynchronous library you can defer execution. Call Teaspoon.execute() +// after everything has been loaded. Simple example of a timeout: +// +// Teaspoon.defer = true +// setTimeout(Teaspoon.execute, 1000) +// +// Matching files +// By default Teaspoon will look for files that match _spec.{js,js.coffee,.coffee}. Add a filename_spec.js file in your +// spec path and it'll be included in the default suite automatically. If you want to customize suites, check out the +// configuration in config/initializers/teaspoon.rb +// +// Manifest +// If you'd rather require your spec files manually (to control order for instance) you can disable the suite matcher in +// the configuration and use this file as a manifest. +// +// For more information: http://github.com/modeset/teaspoon +// +// You can require javascript files here. A good place to start is by requiring your application.js. +//= require application + -- cgit v1.2.3