%PDF- <> %âãÏÓ endobj 2 0 obj <> endobj 3 0 obj <>/ExtGState<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI] >>/Annots[ 28 0 R 29 0 R] /MediaBox[ 0 0 595.5 842.25] /Contents 4 0 R/Group<>/Tabs/S>> endobj ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµùÕ5sLOšuY>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<> endobj 2 0 obj<>endobj 2 0 obj<>es 3 0 R>> endobj 2 0 obj<> ox[ 0.000000 0.000000 609.600000 935.600000]/Fi endobj 3 0 obj<> endobj 7 1 obj<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI]>>/Subtype/Form>> stream
// Copyright 2020 the V8 project authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. /** * @fileoverview Test normalization. */ 'use strict'; const sinon = require('sinon'); const helpers = require('./helpers.js'); const sourceHelpers = require('../source_helpers.js'); const { ScriptMutator } = require('../script_mutator.js'); const sandbox = sinon.createSandbox(); function testLoad(testPath, expectedPath) { const mutator = new ScriptMutator({}, helpers.DB_DIR); const source = helpers.loadTestData(testPath); const dependencies = mutator.resolveInputDependencies([source]); const code = sourceHelpers.generateCode(source, dependencies); helpers.assertExpectedResult(expectedPath, code); } describe('V8 dependencies', () => { it('test', () => { testLoad( 'mjsunit/test_load.js', 'mjsunit/test_load_expected.js'); }); it('does not loop indefinitely', () => { testLoad( 'mjsunit/test_load_self.js', 'mjsunit/test_load_self_expected.js'); }); }); describe('Chakra dependencies', () => { it('test', () => { testLoad( 'chakra/load.js', 'chakra/load_expected.js'); }); }); describe('JSTest dependencies', () => { afterEach(() => { sandbox.restore(); }); it('test', () => { const fakeStubs = sourceHelpers.loadSource( helpers.BASE_DIR, 'JSTests/fake_stub.js'); sandbox.stub(sourceHelpers, 'loadResource').callsFake(() => fakeStubs); testLoad('JSTests/load.js', 'JSTests/load_expected.js'); }); }); describe('SpiderMonkey dependencies', () => { it('test', () => { testLoad( 'spidermonkey/test/load.js', 'spidermonkey/test/load_expected.js'); }); });