Skip to content

Commit

Permalink
test: fix
Browse files Browse the repository at this point in the history
  • Loading branch information
alexander-akait committed Nov 8, 2021
1 parent c1c4f69 commit 0b7aa64
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/TerserPlugin.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import path from "path";
import { SourceMapConsumer } from "source-map";
import CopyWebpackPlugin from "copy-webpack-plugin";
import RequestShortener from "webpack/lib/RequestShortener";
import { javascript, SourceMapDevToolPlugin } from "webpack";
import { javascript, SourceMapDevToolPlugin, util } from "webpack";

import del from "del";

Expand Down Expand Up @@ -935,7 +935,7 @@ describe("TerserPlugin", () => {
for (const assetName of Object.keys(assets)) {
const [, webpackHash] = assetName.match(/^.+?\.(.+?)\..+$/);
const { hashDigestLength, hashDigest, hashFunction } = output;
const cryptoHash = crypto
const cryptoHash = util
.createHash(hashFunction)
.update(readAsset(assetName, compiler, stats))
.digest(hashDigest)
Expand Down

0 comments on commit 0b7aa64

Please sign in to comment.