added tests for resetting height on close
This commit is contained in:
parent
859c0b93b5
commit
0629f4fd9c
1 changed files with 9 additions and 3 deletions
|
|
@ -16,13 +16,19 @@ describe("app.views.Publisher", function() {
|
||||||
});
|
});
|
||||||
|
|
||||||
describe("#close", function() {
|
describe("#close", function() {
|
||||||
it("removes the 'active' class from the publisher element", function(){
|
beforeEach(function() {
|
||||||
$(this.view.el).removeClass("closed");
|
this.view.open($.Event());
|
||||||
|
});
|
||||||
|
|
||||||
expect($(this.view.el)).not.toHaveClass("closed");
|
it("removes the 'active' class from the publisher element", function(){
|
||||||
this.view.close($.Event());
|
this.view.close($.Event());
|
||||||
expect($(this.view.el)).toHaveClass("closed");
|
expect($(this.view.el)).toHaveClass("closed");
|
||||||
})
|
})
|
||||||
|
|
||||||
|
it("resets the element's height", function() {
|
||||||
|
this.view.close($.Event());
|
||||||
|
expect($(this.view.el).find("#status_message_fake_text").attr("style")).not.toContain("height");
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
describe("#clear", function() {
|
describe("#clear", function() {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue