From 5851bd5d2b01738c3dab7c0926a45636286be8f4 Mon Sep 17 00:00:00 2001 From: Himanshu Mishra Date: Fri, 19 Feb 2021 11:06:27 +0100 Subject: [PATCH] TechDocs: Use expect.assertions to make sure the error messages are checked --- packages/techdocs-common/src/stages/publish/awsS3.test.ts | 1 + .../techdocs-common/src/stages/publish/azureBlobStorage.test.ts | 1 + .../techdocs-common/src/stages/publish/googleStorage.test.ts | 2 ++ 3 files changed, 4 insertions(+) diff --git a/packages/techdocs-common/src/stages/publish/awsS3.test.ts b/packages/techdocs-common/src/stages/publish/awsS3.test.ts index b98f62e0f5..3d7bd337d2 100644 --- a/packages/techdocs-common/src/stages/publish/awsS3.test.ts +++ b/packages/techdocs-common/src/stages/publish/awsS3.test.ts @@ -120,6 +120,7 @@ describe('AwsS3Publish', () => { }); it('should fail to publish a directory', async () => { + expect.assertions(3); const wrongPathToGeneratedDirectory = path.join( rootDir, 'wrong', diff --git a/packages/techdocs-common/src/stages/publish/azureBlobStorage.test.ts b/packages/techdocs-common/src/stages/publish/azureBlobStorage.test.ts index d8a112a403..cf1ea60592 100644 --- a/packages/techdocs-common/src/stages/publish/azureBlobStorage.test.ts +++ b/packages/techdocs-common/src/stages/publish/azureBlobStorage.test.ts @@ -111,6 +111,7 @@ describe('publishing with valid credentials', () => { }); it('should fail to publish a directory', async () => { + expect.assertions(1); const wrongPathToGeneratedDirectory = path.join( rootDir, 'wrong', diff --git a/packages/techdocs-common/src/stages/publish/googleStorage.test.ts b/packages/techdocs-common/src/stages/publish/googleStorage.test.ts index e0d56db8cc..10da0d476a 100644 --- a/packages/techdocs-common/src/stages/publish/googleStorage.test.ts +++ b/packages/techdocs-common/src/stages/publish/googleStorage.test.ts @@ -117,6 +117,8 @@ describe('GoogleGCSPublish', () => { }); it('should fail to publish a directory', async () => { + expect.assertions(3); + const wrongPathToGeneratedDirectory = path.join( rootDir, 'wrong',