spec/javascripts/coffeescripts/jquery.aa.checkbox-toggler-spec.js.coffee in activeadmin-0.6.0 vs spec/javascripts/coffeescripts/jquery.aa.checkbox-toggler-spec.js.coffee in activeadmin-0.6.1
- old
+ new
@@ -1,24 +1,24 @@
-describe "AA.CheckboxToggler", ->
+describe "ActiveAdmin.CheckboxToggler", ->
beforeEach ->
loadFixtures('checkboxes.html')
@collection = $("#collection")
@toggle_all = @collection.find(".toggle_all")
@checkboxes = @collection.find(":checkbox").not(@toggle_all)
- new AA.CheckboxToggler({}, @collection)
+ new ActiveAdmin.CheckboxToggler({}, @collection)
describe "on init", ->
it "should raise an error if container not found", ->
- expect( => new AA.CheckboxToggler({}) ).toThrow("Container element not found")
+ expect( => new ActiveAdmin.CheckboxToggler({}) ).toThrow("Container element not found")
it "should raise an error if 'toggle all' checkbox not found", ->
@toggle_all.remove()
- expect( => new AA.CheckboxToggler({}, @collection); ).toThrow("'toggle all' checkbox not found")
+ expect( => new ActiveAdmin.CheckboxToggler({}, @collection); ).toThrow("'toggle all' checkbox not found")
describe "'toggle all' checkbox", ->
it "should check all checkboxes when checked", ->
@toggle_all.trigger("click")
expect(@checkboxes).toHaveAttr("checked")