Skip to content
This repository has been archived by the owner on Jun 26, 2020. It is now read-only.

Commit

Permalink
Alter test 'should re-render view if selections are similar if DOM se…
Browse files Browse the repository at this point in the history
…lection is in incorrect place' test on Edge.
  • Loading branch information
jodator committed Dec 5, 2018
1 parent 78e2d74 commit b5ec6f4
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions tests/view/observer/selectionobserver.js
Original file line number Diff line number Diff line change
Expand Up @@ -346,6 +346,12 @@ describe( 'SelectionObserver', () => {
viewDocument.once( 'selectionChange', () => {
// 2. Selection change has been handled.

// Enforce selection change on Edge 18.
if ( env.isEdge ) {
domDocument.getSelection().collapse( domText, 2 );
domDocument.getSelection().extend( domText, 3 );
}

selectionObserver.listenTo( domDocument, 'selectionchange', () => {
// 4. Check if view was re-rendered.
expect( view.render.called ).to.be.true;
Expand Down

0 comments on commit b5ec6f4

Please sign in to comment.