Skip to content

Commit

Permalink
test: fix
Browse files Browse the repository at this point in the history
  • Loading branch information
alexander-akait committed Aug 15, 2024
1 parent 78178ff commit c2f040a
Showing 1 changed file with 45 additions and 0 deletions.
45 changes: 45 additions & 0 deletions test/middleware.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -841,6 +841,11 @@ describe.each([
const outputPath = path.resolve(__dirname, "./outputs/basic-test");

beforeAll(async () => {
await fs.promises.rm(path.resolve(__dirname, "./outputs/"), {
recursive: true,
force: true,
});

compiler = getCompiler({
...webpackConfig,
output: {
Expand Down Expand Up @@ -1419,6 +1424,11 @@ describe.each([

describe("should work in multi-compiler mode with `devServer` false", () => {
beforeAll(async () => {
await fs.promises.rm(path.resolve(__dirname, "./outputs/"), {
recursive: true,
force: true,
});

const compiler = getCompiler(webpackMultiDevServerFalseConfig);

[server, req, instance] = await frameworkFactory(
Expand Down Expand Up @@ -3605,6 +3615,11 @@ describe.each([
let compiler;

beforeAll(async () => {
await fs.promises.rm(path.resolve(__dirname, "./outputs/"), {
recursive: true,
force: true,
});

compiler = getCompiler({
...webpackConfig,
output: {
Expand Down Expand Up @@ -3694,6 +3709,11 @@ describe.each([
let compiler;

beforeAll(async () => {
await fs.promises.rm(outputPath, {
recursive: true,
force: true,
});

compiler = getCompiler({
...webpackConfig,
output: {
Expand Down Expand Up @@ -3823,6 +3843,11 @@ describe.each([
let compiler;

beforeAll(async () => {
await fs.promises.rm(path.resolve(__dirname, "./outputs/"), {
recursive: true,
force: true,
});

compiler = getCompiler({
...webpackConfig,
output: {
Expand Down Expand Up @@ -3873,6 +3898,11 @@ describe.each([
let compiler;

beforeAll(async () => {
await fs.promises.rm(path.resolve(__dirname, "./outputs/"), {
recursive: true,
force: true,
});

compiler = getCompiler({
...webpackConfig,
output: {
Expand Down Expand Up @@ -3923,6 +3953,11 @@ describe.each([
let compiler;

beforeAll(async () => {
await fs.promises.rm(path.resolve(__dirname, "./outputs/"), {
recursive: true,
force: true,
});

compiler = getCompiler({
...webpackQueryStringConfig,
output: {
Expand Down Expand Up @@ -3971,6 +4006,11 @@ describe.each([
let compiler;

beforeAll(async () => {
await fs.promises.rm(path.resolve(__dirname, "./outputs/"), {
recursive: true,
force: true,
});

compiler = getCompiler([
{
...webpackMultiWatchOptionsConfig[0],
Expand Down Expand Up @@ -4044,6 +4084,11 @@ describe.each([
let hash;

beforeAll(async () => {
await fs.promises.rm(path.resolve(__dirname, "./outputs/"), {
recursive: true,
force: true,
});

compiler = getCompiler({
...webpackConfig,
...{
Expand Down

0 comments on commit c2f040a

Please sign in to comment.