diff --git a/tests/integration/simple-app.test.ts b/tests/integration/simple-app.test.ts index f70eed2871..2d2acf46bf 100644 --- a/tests/integration/simple-app.test.ts +++ b/tests/integration/simple-app.test.ts @@ -149,21 +149,21 @@ test('Test that the simple next app is working', async (ctx) describe('verification', () => { test("Should warn if publish dir doesn't exist", async (ctx) => { await createFixture('simple', ctx) - expect(() => runPlugin(ctx, { PUBLISH_DIR: 'no-such-directory' })).rejects.toThrowError( + await expect(() => runPlugin(ctx, { PUBLISH_DIR: 'no-such-directory' })).rejects.toThrowError( /Your publish directory was not found at: \S+no-such-directory. Please check your build settings/, ) }) test('Should warn if publish dir is root', async (ctx) => { await createFixture('simple', ctx) - expect(() => runPlugin(ctx, { PUBLISH_DIR: '.' })).rejects.toThrowError( + await expect(() => runPlugin(ctx, { PUBLISH_DIR: '.' })).rejects.toThrowError( 'Your publish directory cannot be the same as the base directory of your site. Please check your build settings', ) }) test('Should warn if publish dir is root (package path variant)', async (ctx) => { await createFixture('simple', ctx) - expect(() => + await expect(() => runPlugin(ctx, { PUBLISH_DIR: 'app/.', PACKAGE_PATH: 'app' }), ).rejects.toThrowError( 'Your publish directory cannot be the same as the base directory of your site. Please check your build settings', @@ -172,7 +172,7 @@ describe('verification', () => { test('Should warn if publish dir is not set to Next.js output directory', async (ctx) => { await createFixture('simple', ctx) - expect(() => runPlugin(ctx, { PUBLISH_DIR: 'public' })).rejects.toThrowError( + await expect(() => runPlugin(ctx, { PUBLISH_DIR: 'public' })).rejects.toThrowError( 'Your publish directory does not contain expected Next.js build output. Please check your build settings', ) })