diff --git a/packages/aws-cdk-lib/aws-lambda-nodejs/test/util.test.ts b/packages/aws-cdk-lib/aws-lambda-nodejs/test/util.test.ts index 71c0171897d57..fab4541170a35 100644 --- a/packages/aws-cdk-lib/aws-lambda-nodejs/test/util.test.ts +++ b/packages/aws-cdk-lib/aws-lambda-nodejs/test/util.test.ts @@ -123,14 +123,14 @@ describe('exec', () => { test('non zero status', () => { const spawnSyncMock = jest.spyOn(child_process, 'spawnSync').mockReturnValue({ status: 999, - stderr: Buffer.from('error occured'), + stderr: Buffer.from('error occurred'), stdout: Buffer.from('stdout'), pid: 123, output: ['stdout', 'stderr'], signal: null, }); - expect(() => exec('cmd', ['arg1', 'arg2'])).toThrow('error occured'); + expect(() => exec('cmd', ['arg1', 'arg2'])).toThrow('error occurred'); spawnSyncMock.mockRestore(); });