summaryrefslogtreecommitdiff
path: root/web-ui/test/spec/page
diff options
context:
space:
mode:
authorPatrick Maia <pixelated-team+patrick@thoughtworks.com>2014-08-08 17:51:33 -0300
committerPatrick Maia <patrickjourdanmaia@gmail.com>2014-08-08 17:51:33 -0300
commit97e762a0832593031ae71ab1e11d4c0e377a00f4 (patch)
tree213e835f4effbaf97f0922e5941065b1329d0501 /web-ui/test/spec/page
parentf22a6a32e901f52b2b3f2b3fd8625c43302ff001 (diff)
replaces Smail by Pixelated in all js files
Diffstat (limited to 'web-ui/test/spec/page')
-rw-r--r--web-ui/test/spec/page/pane_contract_expand.spec.js10
-rw-r--r--web-ui/test/spec/page/router.spec.js16
2 files changed, 13 insertions, 13 deletions
diff --git a/web-ui/test/spec/page/pane_contract_expand.spec.js b/web-ui/test/spec/page/pane_contract_expand.spec.js
index 803f688c..9a09edb2 100644
--- a/web-ui/test/spec/page/pane_contract_expand.spec.js
+++ b/web-ui/test/spec/page/pane_contract_expand.spec.js
@@ -1,4 +1,4 @@
-/*global Smail */
+/*global Pixelated */
/*global afterEach */
'use strict';
@@ -27,28 +27,28 @@ describeComponent('page/pane_contract_expand', function () {
});
it('contracts middle pane and expands right pane on mail open', function () {
- $(document).trigger(Smail.events.ui.mail.open);
+ $(document).trigger(Pixelated.events.ui.mail.open);
expect($('#middle-pane-container').attr('class')).toEqual(this.component.attr.MIDDLE_PANE_CONTRACT_CLASSES);
expect($('#right-pane').attr('class')).toEqual(this.component.attr.RIGHT_PANE_EXPAND_CLASSES);
});
it('contracts middle pane and expands right pane on open compose box', function () {
- $(document).trigger(Smail.events.dispatchers.rightPane.openComposeBox);
+ $(document).trigger(Pixelated.events.dispatchers.rightPane.openComposeBox);
expect($('#middle-pane-container').attr('class')).toEqual(this.component.attr.MIDDLE_PANE_CONTRACT_CLASSES);
expect($('#right-pane').attr('class')).toEqual(this.component.attr.RIGHT_PANE_EXPAND_CLASSES);
});
it('contracts middle pane and expands right pane on open draft', function () {
- $(document).trigger(Smail.events.dispatchers.rightPane.openDraft);
+ $(document).trigger(Pixelated.events.dispatchers.rightPane.openDraft);
expect($('#middle-pane-container').attr('class')).toEqual(this.component.attr.MIDDLE_PANE_CONTRACT_CLASSES);
expect($('#right-pane').attr('class')).toEqual(this.component.attr.RIGHT_PANE_EXPAND_CLASSES);
});
it('expands middle pane and contracts right pane on event on open no message selected pane', function () {
- $(document).trigger(Smail.events.dispatchers.rightPane.openNoMessageSelected);
+ $(document).trigger(Pixelated.events.dispatchers.rightPane.openNoMessageSelected);
expect($('#middle-pane-container').attr('class')).toEqual(this.component.attr.MIDDLE_PANE_EXPAND_CLASSES);
expect($('#right-pane').attr('class')).toEqual(this.component.attr.RIGHT_PANE_CONTRACT_CLASSES);
diff --git a/web-ui/test/spec/page/router.spec.js b/web-ui/test/spec/page/router.spec.js
index 0b5b6b32..0eb8977d 100644
--- a/web-ui/test/spec/page/router.spec.js
+++ b/web-ui/test/spec/page/router.spec.js
@@ -1,4 +1,4 @@
-/*global Smail */
+/*global Pixelated */
/*global jasmine */
describeComponent('page/router', function () {
'use strict';
@@ -12,29 +12,29 @@ describeComponent('page/router', function () {
});
it('pushes the state with the tag and the url', function () {
- $(document).trigger(Smail.events.router.pushState, { tag: 'inbox'});
+ $(document).trigger(Pixelated.events.router.pushState, { tag: 'inbox'});
expect(fakeHistory.pushState).toHaveBeenCalledWith(jasmine.objectContaining({ tag: 'inbox' }), '', '/#/inbox');
});
it('pushes the state with mailIdent', function () {
- $(document).trigger(Smail.events.router.pushState, { tag: 'inbox', mailIdent: 1});
+ $(document).trigger(Pixelated.events.router.pushState, { tag: 'inbox', mailIdent: 1});
expect(fakeHistory.pushState).toHaveBeenCalledWith(jasmine.objectContaining({ tag: 'inbox', mailIdent: 1 }), '', '/#/inbox/mail/1');
});
it('pushes the state with mailIdent even if mail ident is 0 (that happens for drafts)', function () {
- $(document).trigger(Smail.events.router.pushState, { tag: 'inbox', mailIdent: 0});
+ $(document).trigger(Pixelated.events.router.pushState, { tag: 'inbox', mailIdent: 0});
expect(fakeHistory.pushState).toHaveBeenCalledWith(jasmine.objectContaining({ tag: 'inbox', mailIdent: 0 }), '', '/#/inbox/mail/0');
});
it('pushes the state with the displayNoMessage boolean forwarded from the event', function () {
- $(document).trigger(Smail.events.router.pushState, { tag: 'inbox', mailIdent: 0});
+ $(document).trigger(Pixelated.events.router.pushState, { tag: 'inbox', mailIdent: 0});
expect(fakeHistory.pushState).toHaveBeenCalledWith(jasmine.objectContaining({ isDisplayNoMessageSelected: false}), '', '/#/inbox/mail/0');
- $(document).trigger(Smail.events.router.pushState, { tag: 'inbox', mailIdent: 0, isDisplayNoMessageSelected: true});
+ $(document).trigger(Pixelated.events.router.pushState, { tag: 'inbox', mailIdent: 0, isDisplayNoMessageSelected: true});
expect(fakeHistory.pushState).toHaveBeenCalledWith(jasmine.objectContaining({ isDisplayNoMessageSelected: true}), '', '/#/inbox/mail/0');
});
@@ -43,7 +43,7 @@ describeComponent('page/router', function () {
var urlParams = require("page/router/url_params");
spyOn(urlParams, 'getTag').andReturn('tag');
- var selectTagEvent = spyOnEvent(document, Smail.events.ui.tag.select);
+ var selectTagEvent = spyOnEvent(document, Pixelated.events.ui.tag.select);
this.component.smailPopState({ state: {tag: undefined} });
@@ -54,7 +54,7 @@ describeComponent('page/router', function () {
var urlParams = require("page/router/url_params");
spyOn(urlParams, 'getTag').andReturn('tag');
- var displayNoMessageEvent = spyOnEvent(document, Smail.events.dispatchers.rightPane.openNoMessageSelectedWithoutPushState);
+ var displayNoMessageEvent = spyOnEvent(document, Pixelated.events.dispatchers.rightPane.openNoMessageSelectedWithoutPushState);
this.component.smailPopState({ state: {tag: undefined, isDisplayNoMessageSelected: false} });