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
(function($){ | |
$.fn.check = function(){ | |
if (!this.is(':checked')) { | |
this.toggleChecked(); | |
} | |
return this; | |
}; | |
$.fn.uncheck = function(){ |
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
var swfup = new SWFUpload({ | |
post_params : { | |
authenticity_token : '<%= u form_authenticity_token %>' | |
session: '<%= u request.env['rack.request.cookie_hash'].try(:[], Rails.application.config.session_options[:key]) %>' | |
} | |
}); |
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
beforeEach(function() { | |
this.addMatchers({ | |
toBeVisible: function() { | |
var actual = $(this.actual); | |
var basicMessage = "be visible"; | |
return this._reportWithNonExistant( | |
actual.is(':visible'), | |
basicMessage, | |
"Expected '$(" + actual.selector + ")' to " + basicMessage + " but was not" |