Lines Matching defs:const
3 const common = require('../common');
15 const { debuglog } = require('util');
16 const debug = debuglog('test');
17 const tmpdir = require('../common/tmpdir');
18 const assert = require('assert');
19 const { spawnSync, spawn } = require('child_process');
20 const crypto = require('crypto');
21 const fs = require('fs');
22 const path = require('path');
23 const { pathToFileURL } = require('url');
25 const cpus = require('os').availableParallelism();
28 const values = [];
30 const h = crypto.createHash(algo);
35 const h = crypto.createHash(algo);
42 const policyPath = './policy.json';
43 const parentBody = {
72 const toSpawn = [];
83 const config = toSpawn.shift();
84 const {
94 const testId = newTestId();
95 const configDirPath = path.join(
99 const tmpPolicyPath = path.join(
103 const cliPolicy = willDeletePolicy ? tmpPolicyPath : policyPath;
106 const manifest = {
110 const manifestPath = path.join(configDirPath, policyPath);
111 for (const [resourcePath, { body, integrities }] of Object.entries(
114 const filePath = path.join(configDirPath, resourcePath);
123 const manifestBody = JSON.stringify(manifest);
128 const spawnArgs = [
152 const stdout = [];
153 const stderr = [];
154 const child = spawn(...spawnArgs);
187 const { status } = spawnSync(
197 const enoentFilepath = path.join(tmpdir.path, 'enoent');
203 const { status } = spawnSync(
220 const keys = Object.keys(configurations);
224 const config = keys[0];
225 const { [config]: values, ...otherConfigs } = configurations;
230 const tests = new Set();
241 for (const permutation of permutations({
251 const parentPath = `./parent${permutation.parentExtension}`;
252 const parentFormat = fileExtensionFormat(permutation.parentExtension);
253 const depFormat = fileExtensionFormat(permutation.depExtension);
259 const depPath = `./dep${permutation.depExtension}`;
260 const entryPath = parentPath;
262 const resources = {
321 for (const config of tests) {
322 const parsed = JSON.parse(config);