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

Commit

Permalink
Fix the test for the forceValue option.
Browse files Browse the repository at this point in the history
  • Loading branch information
jodator committed Jan 3, 2020
1 parent f3bcb5b commit 84345c5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/restrictededitingexceptioncommand.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ describe( 'RestrictedEditingExceptionCommand', () => {
it( 'should remove attribute from text node if a text has the non-restricted attribute (forceValue="false")', () => {
setData( model, '<p>abc<$text restrictedEditingException="true">foo[]bar</$text>baz</p>' );

command.execute();
command.execute( { forceValue: false } );

expect( model.document.selection.hasAttribute( 'restrictedEditingException' ) ).to.be.false;
expect( getData( model ) ).to.equal( '<p>abcfoo[]barbaz</p>' );
Expand All @@ -157,7 +157,7 @@ describe( 'RestrictedEditingExceptionCommand', () => {
it( 'should not remove attribute from text node if a text has the non-restricted attribute (forceValue="true")', () => {
setData( model, '<p>abc<$text restrictedEditingException="true">foo[]bar</$text>baz</p>' );

command.execute();
command.execute( { forceValue: true } );

expect( model.document.selection.hasAttribute( 'restrictedEditingException' ) ).to.be.true;
expect( getData( model ) ).to.equal( '<p>abc<$text restrictedEditingException="true">foo[]bar</$text>baz</p>' );
Expand Down

0 comments on commit 84345c5

Please sign in to comment.