8
0
Просмотр исходного кода

Merge pull request #43 from ckeditor/t/42

Tests: Fixed several assertions to consider the initial state of `ToggleAttributeCommand` after the refactoring. Closes #42.
Piotrek Koszuliński 8 лет назад
Родитель
Сommit
b87f5eaa01

+ 3 - 3
packages/ckeditor5-basic-styles/tests/bold.js

@@ -65,13 +65,13 @@ describe( 'Bold', () => {
 
 		expect( boldView.isOn ).to.be.false;
 
-		expect( boldView.isEnabled ).to.be.true;
+		expect( boldView.isEnabled ).to.be.false;
 
 		command.value = true;
 		expect( boldView.isOn ).to.be.true;
 
-		command.isEnabled = false;
-		expect( boldView.isEnabled ).to.be.false;
+		command.isEnabled = true;
+		expect( boldView.isEnabled ).to.be.true;
 	} );
 
 	it( 'should set keystroke in the model', () => {

+ 3 - 3
packages/ckeditor5-basic-styles/tests/italic.js

@@ -65,13 +65,13 @@ describe( 'Italic', () => {
 
 		expect( italicView.isOn ).to.be.false;
 
-		expect( italicView.isEnabled ).to.be.true;
+		expect( italicView.isEnabled ).to.be.false;
 
 		command.value = true;
 		expect( italicView.isOn ).to.be.true;
 
-		command.isEnabled = false;
-		expect( italicView.isEnabled ).to.be.false;
+		command.isEnabled = true;
+		expect( italicView.isEnabled ).to.be.true;
 	} );
 
 	it( 'should set keystroke in the model', () => {