MCPcopy Index your code
hub / github.com/webpack/webpack-bundle-analyzer / expectValidReport

Function expectValidReport

test/analyzer.js:53–64  ·  view source on GitHub ↗
(opts)

Source from the content-addressed store, hash-verified

51}
52
53async function expectValidReport(opts) {
54 const { bundleLabel = "bundle.js", statSize = 141 } = opts || {};
55
56 expect(fs.existsSync(path.resolve(__dirname, "./output/report.html"))).toBe(
57 true,
58 );
59 const chartData = await getChartData();
60 expect(chartData[0]).toMatchObject({
61 label: bundleLabel,
62 statSize,
63 });
64}
65
66function generateJSONReportFrom(statsFilename) {
67 childProcess.execSync(

Callers 1

analyzer.jsFile · 0.70

Calls 1

getChartDataFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…