Skip to content

Commit

Permalink
fix(test): Bug unit test file missing option credential
Browse files Browse the repository at this point in the history
  • Loading branch information
pornchaitippawan committed Nov 20, 2023
1 parent 09fe14f commit 77b3ca7
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/__tests__/cloud-storage.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ jest.mock('fs');

describe('Cloud Storage', () => {
const rootBucketName = 'mock-bucket';
const credentials = {
client_email: 'test-client_email',
private_key: 'test-private_key'
}

let cloudStorageService;
beforeEach(() => {
Expand All @@ -16,7 +20,7 @@ describe('Cloud Storage', () => {
};

// Create an instance of CloudStorageService with mock options
cloudStorageService = new CloudStorageService({ logger }, { bucketName: rootBucketName });
cloudStorageService = new CloudStorageService({ logger }, { credentials , bucketName: rootBucketName });
});

it('should be able to upload file to cloud storage with publicRead', async () => {
Expand Down

0 comments on commit 77b3ca7

Please sign in to comment.