Skip to content

Commit

Permalink
explicitly stopping grow mode in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
e2tha-e committed Sep 6, 2019
1 parent a17f8ae commit dd8a547
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion test/unit/patternlab-viewer.js
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,8 @@ describe('patternlabViewer', function () {
const growIdDuring = fepperUi.uiProps.growId;

setTimeout(() => {
uiFns.stopGrow();

expect(discoModeBefore).to.be.false;
expect(discoIdBefore).to.not.be.ok;
expect(documentStateBefore.activeOrganism).to.be.null;
Expand All @@ -314,7 +316,6 @@ describe('patternlabViewer', function () {
global.location.search = '?grow=true';
const swOrig = uiProps.sw;

$orgs['#sg-size-grow'].dispatchAction('blur');
// Decrease window width so we have a short, but accurate test.
$orgs.window.dispatchAction('innerWidth', uiProps.minViewportWidth + 5);

Expand All @@ -333,6 +334,8 @@ describe('patternlabViewer', function () {
const growIdDuring = fepperUi.uiProps.growId;

setTimeout(() => {
uiFns.stopGrow();

expect(discoModeBefore).to.be.false;
expect(discoIdBefore).to.not.be.ok;
expect(documentStateBefore.activeOrganism).to.be.null;
Expand Down

0 comments on commit dd8a547

Please sign in to comment.