소스 검색

Internal: PendingActions#isPending was renamed to #hasAny. Closes ckeditor/ckeditor5-core#142.

Piotrek Koszuliński 7 년 전
부모
커밋
9bf1c343b2
1개의 변경된 파일6개의 추가작업 그리고 6개의 파일을 삭제
  1. 6 6
      packages/ckeditor5-upload/tests/filerepository.js

+ 6 - 6
packages/ckeditor5-upload/tests/filerepository.js

@@ -104,12 +104,12 @@ describe( 'FileRepository', () => {
 		} );
 
 		it( 'should add pending action when upload is in progress', () => {
-			expect( pendingActions ).to.have.property( 'isPending', false );
+			expect( pendingActions ).to.have.property( 'hasAny', false );
 			expect( Array.from( pendingActions ) ).to.length( 0 );
 
 			fileRepository.createLoader( createNativeFileMock() );
 
-			expect( pendingActions ).to.have.property( 'isPending', true );
+			expect( pendingActions ).to.have.property( 'hasAny', true );
 			expect( Array.from( pendingActions, action => action.message ) ).to.have.members( [ 'Upload in progress 0%.' ] );
 		} );
 
@@ -122,23 +122,23 @@ describe( 'FileRepository', () => {
 		} );
 
 		it( 'should remove pending action when all uploads are finished', () => {
-			expect( pendingActions ).to.have.property( 'isPending', false );
+			expect( pendingActions ).to.have.property( 'hasAny', false );
 			expect( Array.from( pendingActions ) ).to.length( 0 );
 
 			const loader1 = fileRepository.createLoader( createNativeFileMock() );
 			const loader2 = fileRepository.createLoader( createNativeFileMock() );
 
-			expect( pendingActions ).to.have.property( 'isPending', true );
+			expect( pendingActions ).to.have.property( 'hasAny', true );
 			expect( Array.from( pendingActions, action => action.message ) ).to.have.members( [ 'Upload in progress 0%.' ] );
 
 			fileRepository.destroyLoader( loader1 );
 
-			expect( pendingActions ).to.have.property( 'isPending', true );
+			expect( pendingActions ).to.have.property( 'hasAny', true );
 			expect( Array.from( pendingActions, action => action.message ) ).to.have.members( [ 'Upload in progress 0%.' ] );
 
 			fileRepository.destroyLoader( loader2 );
 
-			expect( pendingActions ).to.have.property( 'isPending', false );
+			expect( pendingActions ).to.have.property( 'hasAny', false );
 			expect( Array.from( pendingActions ) ).to.length( 0 );
 		} );