diff --git a/src/after-compile.ts b/src/after-compile.ts index 3a3a3fafc..f322b24a4 100644 --- a/src/after-compile.ts +++ b/src/after-compile.ts @@ -6,6 +6,7 @@ import * as constants from './constants'; import { getEmitFromWatchHost, getEmitOutput } from './instances'; import { FilePathKey, + LoaderOptions, TSFiles, TSInstance, WebpackModule, @@ -17,6 +18,7 @@ import { formatErrors, isReferencedFile, populateReverseDependencyGraph, + tsLoaderSource, } from './utils'; export function makeAfterCompile( @@ -41,7 +43,7 @@ export function makeAfterCompile( callback(); return; } - removeCompilationTSLoaderErrors(compilation); + removeCompilationTSLoaderErrors(compilation, instance.loaderOptions); provideCompilerOptionDiagnosticErrorsToWebpack( getCompilerOptionDiagnostics, @@ -235,7 +237,7 @@ function provideErrorsToWebpack( const associatedModules = modules.get(instance.filePathKeyMapper(fileName)); if (associatedModules !== undefined) { associatedModules.forEach(module => { - removeModuleTSLoaderError(module); + removeModuleTSLoaderError(module, loaderOptions); // append errors const formattedErrors = formatErrors( @@ -280,6 +282,7 @@ function provideSolutionErrorsToWebpack( ) { if ( !instance.solutionBuilderHost || + instance.solutionBuilderHost.defaultInstance !== instance || !( instance.solutionBuilderHost.diagnostics.global.length || instance.solutionBuilderHost.diagnostics.perFile.size @@ -299,7 +302,7 @@ function provideSolutionErrorsToWebpack( const associatedModules = modules.get(filePath); if (associatedModules !== undefined) { associatedModules.forEach(module => { - removeModuleTSLoaderError(module); + removeModuleTSLoaderError(module, loaderOptions); // append errors const formattedErrors = formatErrors( @@ -430,7 +433,10 @@ function provideAssetsFromSolutionBuilderHost( instance: TSInstance, compilation: webpack.compilation.Compilation ) { - if (instance.solutionBuilderHost) { + if ( + instance.solutionBuilderHost && + instance.solutionBuilderHost.defaultInstance === instance + ) { // written files outputFilesToAsset(instance.solutionBuilderHost.writtenFiles, compilation); instance.solutionBuilderHost.writtenFiles.length = 0; @@ -445,14 +451,18 @@ function provideAssetsFromSolutionBuilderHost( * the loader, we need to detect and remove any pre-existing errors. */ function removeCompilationTSLoaderErrors( - compilation: webpack.compilation.Compilation + compilation: webpack.compilation.Compilation, + loaderOptions: LoaderOptions ) { compilation.errors = compilation.errors.filter( - error => error.loaderSource !== 'ts-loader' + error => error.loaderSource !== tsLoaderSource(loaderOptions) ); } -function removeModuleTSLoaderError(module: WebpackModule) { +function removeModuleTSLoaderError( + module: WebpackModule, + loaderOptions: LoaderOptions +) { /** * Since webpack 5, the `errors` property is deprecated, * so we can check if some methods for reporting errors exist. @@ -464,11 +474,13 @@ function removeModuleTSLoaderError(module: WebpackModule) { Array.from(warnings || []).forEach(warning => module.addWarning(warning)); Array.from(errors || []) - .filter((error: any) => error.loaderSource !== 'ts-loader') + .filter( + (error: any) => error.loaderSource !== tsLoaderSource(loaderOptions) + ) .forEach(error => module.addError(error)); } else { module.errors = module.errors.filter( - error => error.loaderSource !== 'ts-loader' + error => error.loaderSource !== tsLoaderSource(loaderOptions) ); } } diff --git a/src/instances.ts b/src/instances.ts index 18a0c18a9..7d5d08c10 100644 --- a/src/instances.ts +++ b/src/instances.ts @@ -35,6 +35,10 @@ import { import { makeWatchRun } from './watch-run'; const instances = {} as TSInstances; +const solutionBuilderHosts = new Map< + FilePathKey, + NonNullable +>(); /** * The loader is executed once for each file seen by webpack. However, we need to keep @@ -60,7 +64,13 @@ export function getTypeScriptInstance( const compiler = getCompiler(loaderOptions, log); if (compiler.errorMessage !== undefined) { - return { error: makeError(colors.red(compiler.errorMessage), undefined) }; + return { + error: makeError( + loaderOptions, + colors.red(compiler.errorMessage), + undefined + ), + }; } return successfulTypeScriptInstance( @@ -121,6 +131,7 @@ function successfulTypeScriptInstance( const { message, file } = configFileAndPath.configFileError; return { error: makeError( + loaderOptions, colors.red('error while reading tsconfig.json:' + EOL + message), file ), @@ -151,6 +162,7 @@ function successfulTypeScriptInstance( return { error: makeError( + loaderOptions, colors.red('error while parsing tsconfig.json'), configFilePath ), @@ -223,6 +235,7 @@ function successfulTypeScriptInstance( } catch (exc) { return { error: makeError( + loaderOptions, colors.red( `A file specified in tsconfig.json could not be found: ${normalizedFilePath!}` ), @@ -415,25 +428,53 @@ export function buildSolutionReferences( if (!instance.solutionBuilderHost) { // Use solution builder instance.log.logInfo('Using SolutionBuilder api'); - const scriptRegex = getScriptRegexp(instance); - instance.solutionBuilderHost = makeSolutionBuilderHost( - scriptRegex, - loader, - instance - ); - instance.solutionBuilder = instance.compiler.createSolutionBuilderWithWatch( - instance.solutionBuilderHost, - instance.configParseResult.projectReferences!.map(ref => ref.path), - { verbose: true } - ); - instance.solutionBuilder!.build(); - ensureAllReferences(instance); + const key = instance.filePathKeyMapper(instance.configFilePath!); + const existing = getExistingSolutionBuilderHost(key); + if (existing) { + instance.log.logInfo( + `Reusing existing Solution builder:: ${existing.defaultInstance.configFilePath}` + ); + instance.solutionBuilderHost = existing; + instance.solutionBuilderHost.instances.set( + instance.loaderOptions.instance, + instance + ); + ensureAllReferences(instance); + instance.solutionBuilderHost.buildReferences(); + } else if (instance.configParseResult.projectReferences?.length) { + const scriptRegex = getScriptRegexp(instance); + instance.solutionBuilderHost = makeSolutionBuilderHost( + scriptRegex, + loader, + instance + ); + const solutionBuilder = instance.compiler.createSolutionBuilderWithWatch( + instance.solutionBuilderHost, + instance.configParseResult.projectReferences!.map(ref => ref.path), + { verbose: true } + ); + solutionBuilder.build(); + ensureAllReferences(instance); + solutionBuilderHosts.set(key, instance.solutionBuilderHost); + } } else { instance.solutionBuilderHost.buildReferences(); } } +function getExistingSolutionBuilderHost(key: FilePathKey) { + const existing = solutionBuilderHosts.get(key); + if (existing) return existing; + for (const solutionBuilderHost of solutionBuilderHosts.values()) { + if (solutionBuilderHost.configFileInfo.has(key)) { + return solutionBuilderHost; + } + } + return undefined; +} + function ensureAllReferences(instance: TSInstance) { + const defaultInstance = instance.solutionBuilderHost!.defaultInstance; // Return result from the json without errors so that the extra errors from config are digested here for (const configInfo of instance.solutionBuilderHost!.configFileInfo.values()) { if (!configInfo.config) { @@ -444,12 +485,17 @@ function ensureAllReferences(instance: TSInstance) { const resolvedFileName = instance.filePathKeyMapper(file); const existing = instance.otherFiles.get(resolvedFileName); if (!existing) { - instance.otherFiles.set(resolvedFileName, { - fileName: path.resolve(file), - version: 1, - text: instance.compiler.sys.readFile(file), - modifiedTime: instance.compiler.sys.getModifiedTime!(file), - }); + instance.otherFiles.set( + resolvedFileName, + defaultInstance === instance + ? { + fileName: path.resolve(file), + version: 1, + text: instance.compiler.sys.readFile(file), + modifiedTime: instance.compiler.sys.getModifiedTime!(file), + } + : defaultInstance.otherFiles.get(resolvedFileName)! + ); } }); } diff --git a/src/interfaces.ts b/src/interfaces.ts index e90524ae2..589a0d7ef 100644 --- a/src/interfaces.ts +++ b/src/interfaces.ts @@ -129,10 +129,12 @@ export interface SolutionBuilderWithWatchHost typescript.EmitAndSemanticDiagnosticsBuilderProgram >, WatchFactory { + defaultInstance: TSInstance; + instances: Map; diagnostics: SolutionDiagnostics; writtenFiles: OutputFile[]; configFileInfo: Map; - outputAffectingInstanceVersion: Map; + outputAffectingInstanceVersion: Map>; getOutputFileKeyFromReferencedProject( outputFileName: string ): FilePathKey | undefined; @@ -204,9 +206,6 @@ export interface TSInstance { reportTranspileErrors?: boolean; solutionBuilderHost?: SolutionBuilderWithWatchHost; - solutionBuilder?: typescript.SolutionBuilder< - typescript.EmitAndSemanticDiagnosticsBuilderProgram - >; configFilePath: string | undefined; filePathKeyMapper: (fileName: string) => FilePathKey; diff --git a/src/servicesHost.ts b/src/servicesHost.ts index 9ecf3a6dd..9da7d459f 100644 --- a/src/servicesHost.ts +++ b/src/servicesHost.ts @@ -215,17 +215,9 @@ export function makeServicesHost( if (file) { return file.version.toString(); } - const outputFileAndKey = - instance.solutionBuilderHost && - instance.solutionBuilderHost.getOutputFileAndKeyFromReferencedProject( - fileName - ); - if (outputFileAndKey !== undefined) { - instance.solutionBuilderHost!.outputAffectingInstanceVersion.set( - outputFileAndKey.key, - true - ); - } + const outputFileAndKey = getOutputFileAndKeyAffectingInstanceVersion( + fileName + ); return outputFileAndKey && outputFileAndKey.outputFile ? outputFileAndKey.outputFile.version.toString() : ''; @@ -240,14 +232,10 @@ export function makeServicesHost( if (file === undefined) { if (instance.solutionBuilderHost) { - const outputFileAndKey = instance.solutionBuilderHost.getOutputFileAndKeyFromReferencedProject( + const outputFileAndKey = getOutputFileAndKeyAffectingInstanceVersion( fileName ); if (outputFileAndKey !== undefined) { - instance.solutionBuilderHost!.outputAffectingInstanceVersion.set( - outputFileAndKey.key, - true - ); return outputFileAndKey && outputFileAndKey.outputFile ? compiler.ScriptSnapshot.fromString( outputFileAndKey.outputFile.text @@ -306,6 +294,28 @@ export function makeServicesHost( }; return servicesHost; + + function getOutputFileAndKeyAffectingInstanceVersion(fileName: string) { + const outputFileAndKey = + instance.solutionBuilderHost && + instance.solutionBuilderHost.getOutputFileAndKeyFromReferencedProject( + fileName + ); + if (outputFileAndKey !== undefined) { + let outputAffectingInstanceVersion = instance.solutionBuilderHost!.outputAffectingInstanceVersion.get( + instance.loaderOptions.instance + ); + if (!outputAffectingInstanceVersion) { + outputAffectingInstanceVersion = new Map(); + instance.solutionBuilderHost!.outputAffectingInstanceVersion.set( + instance.loaderOptions.instance, + outputAffectingInstanceVersion + ); + } + outputAffectingInstanceVersion.set(outputFileAndKey.key, true); + } + return outputFileAndKey; + } } function makeResolvers( @@ -785,7 +795,10 @@ export function makeSolutionBuilderHost( ); const outputFiles = new Map(); const writtenFiles: OutputFile[] = []; - const outputAffectingInstanceVersion = new Map(); + const outputAffectingInstanceVersion = new Map< + string, + Map + >(); let timeoutId: [(...args: any[]) => void, any[]] | undefined; const symlinkedDirectories = new Map(); @@ -798,6 +811,8 @@ export function makeSolutionBuilderHost( addCache(cachedSys); const configFileInfo = new Map(); + const instances = new Map(); + instances.set(instance.loaderOptions.instance, instance); const solutionBuilderHost: SolutionBuilderWithWatchHost = { ...compiler.createSolutionBuilderWithWatchHost( compiler.sys, @@ -808,6 +823,8 @@ export function makeSolutionBuilderHost( ), useCaseSensitiveFileNames: () => useCaseSensitiveFileNames(compiler, instance.loaderOptions), + defaultInstance: instance, + instances, diagnostics, ...createWatchFactory(filePathKeyMapper, compiler), // Overrides @@ -823,7 +840,6 @@ export function makeSolutionBuilderHost( }, writeFile: (name, text, writeByteOrderMark) => { const key = filePathKeyMapper(name); - updateFileWithText(instance, key, name, () => text); const existing = outputFiles.get(key); const newOutputFile: OutputFile = { name, @@ -838,30 +854,33 @@ export function makeSolutionBuilderHost( }; outputFiles.set(key, newOutputFile); writtenFiles.push(newOutputFile); - if ( - outputAffectingInstanceVersion.has(key) && - (!existing || existing.text !== text) - ) { - instance.version++; - } - if ( - instance.watchHost && - !instance.files.has(key) && - !instance.otherFiles.has(key) - ) { - // If file wasnt updated in files or other files of instance, let watch host know of the change - if (!existing) { - instance.hasUnaccountedModifiedFiles = - instance.watchHost.invokeFileWatcher( - name, - compiler.FileWatcherEventKind.Created - ) || instance.hasUnaccountedModifiedFiles; - } else if (existing.version !== newOutputFile.version) { - instance.hasUnaccountedModifiedFiles = - instance.watchHost.invokeFileWatcher( - name, - compiler.FileWatcherEventKind.Changed - ) || instance.hasUnaccountedModifiedFiles; + for (const [instanceId, instance] of instances) { + updateFileWithText(instance, key, name, () => text); + if ( + outputAffectingInstanceVersion.get(instanceId)?.has(key) && + (!existing || existing.text !== text) + ) { + instance.version++; + } + if ( + instance.watchHost && + !instance.files.has(key) && + !instance.otherFiles.has(key) + ) { + // If file wasnt updated in files or other files of instance, let watch host know of the change + if (!existing) { + instance.hasUnaccountedModifiedFiles = + instance.watchHost.invokeFileWatcher( + name, + compiler.FileWatcherEventKind.Created + ) || instance.hasUnaccountedModifiedFiles; + } else if (existing.version !== newOutputFile.version) { + instance.hasUnaccountedModifiedFiles = + instance.watchHost.invokeFileWatcher( + name, + compiler.FileWatcherEventKind.Changed + ) || instance.hasUnaccountedModifiedFiles; + } } } compiler.sys.writeFile(name, text, writeByteOrderMark); @@ -1240,6 +1259,7 @@ export function getSolutionErrors(instance: TSInstance, context: string) { const solutionErrors: WebpackError[] = []; if ( instance.solutionBuilderHost && + instance.solutionBuilderHost.defaultInstance === instance && instance.solutionBuilderHost.diagnostics.transpileErrors.length ) { instance.solutionBuilderHost.diagnostics.transpileErrors.forEach( diff --git a/src/utils.ts b/src/utils.ts index 0d2345c00..f7938959c 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -100,6 +100,7 @@ export function formatErrors( : loaderOptions.errorFormatter(errorInfo, colors); const error = makeError( + loaderOptions, message, merge.file === undefined ? errorInfo.file : merge.file, position === undefined @@ -124,6 +125,7 @@ export function fsReadFile( } export function makeError( + loaderOptions: LoaderOptions, message: string, file: string | undefined, location?: { line: number; character: number } @@ -132,10 +134,14 @@ export function makeError( message, location, file, - loaderSource: 'ts-loader', + loaderSource: tsLoaderSource(loaderOptions), }; } +export function tsLoaderSource(loaderOptions: LoaderOptions) { + return `ts-loader-${loaderOptions.instance}`; +} + export function appendSuffixIfMatch( patterns: (RegExp | string)[], filePath: string, @@ -281,10 +287,7 @@ export function ensureProgram(instance: TSInstance) { export function supportsSolutionBuild(instance: TSInstance) { return ( - !!instance.configFilePath && - !!instance.loaderOptions.projectReferences && - !!instance.configParseResult.projectReferences && - !!instance.configParseResult.projectReferences.length + !!instance.configFilePath && !!instance.loaderOptions.projectReferences ); } diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/app/app.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/app/app.ts new file mode 100644 index 000000000..1a59cb493 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/app/app.ts @@ -0,0 +1,5 @@ +import { lib } from '../lib'; +import { utils } from "../utils"; + +console.log(lib.one, lib.two, lib.three); +utils(); diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/app/tsconfig.json b/test/comparison-tests/projectReferencesMultipleDifferentInstance/app/tsconfig.json new file mode 100644 index 000000000..50c3bdfa3 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/app/tsconfig.json @@ -0,0 +1,12 @@ +{ + "compilerOptions": { + "types": [] + }, + "files": [ + "./app.ts" + ], + "references": [ + { "path": "../lib" }, + { "path": "../utils" }, + ] +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/app/webpack.config.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/app/webpack.config.js new file mode 100644 index 000000000..514a7fcf0 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/app/webpack.config.js @@ -0,0 +1,22 @@ +var path = require('path') + +module.exports = { + mode: 'development', + entry: './app.ts', + output: { + filename: 'bundle.js' + }, + resolve: { + extensions: ['.ts', '.js'] + }, + module: { + rules: [ + { test: /(app|lib|common|indirect).+\.ts$/, loader: 'ts-loader', options: { projectReferences: true } }, + { test: /utils.+\.ts$/, loader: 'ts-loader', options: { instance: 'different', projectReferences: true } } + ] + } +} + +// for test harness purposes only, you would not need this in a normal project +module.exports.resolveLoader = { alias: { 'ts-loader': require('path').join(__dirname, "../../../../index.js") } } + diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/common/index.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/common/index.ts new file mode 100644 index 000000000..cee4c5145 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/common/index.ts @@ -0,0 +1,3 @@ +export function common() { + return 30; +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/common/tsconfig.json b/test/comparison-tests/projectReferencesMultipleDifferentInstance/common/tsconfig.json new file mode 100644 index 000000000..0710dd495 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/common/tsconfig.json @@ -0,0 +1,6 @@ +{ + "compilerOptions": { + "composite": true, + "types": [] + } +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/app/bundle.js new file mode 100644 index 000000000..041014d08 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 30;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/common/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/common/index.d.ts new file mode 100644 index 000000000..78cb4cd49 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/common/index.d.ts @@ -0,0 +1 @@ +export declare function common(): number; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/common/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/common/index.js new file mode 100644 index 000000000..c561b2cc0 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/common/index.js @@ -0,0 +1,7 @@ +"use strict"; +exports.__esModule = true; +exports.common = void 0; +function common() { + return 30; +} +exports.common = common; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/common/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/common/tsconfig.tsbuildinfo new file mode 100644 index 000000000..3fc50b166 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/common/tsconfig.tsbuildinfo @@ -0,0 +1,55 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "./index.ts": { + "version": "83a8bcfe78ca61ceac765c205ef0435e93f65e7bc386ea12d21e0c963a7e824e", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": {}, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/indirect/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/indirect/index.d.ts new file mode 100644 index 000000000..73d752279 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/indirect/index.d.ts @@ -0,0 +1,5 @@ +export declare const lib: { + one: number; + two: number; + three: number; +}; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/indirect/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/indirect/index.js new file mode 100644 index 000000000..b7785ef20 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/indirect/index.js @@ -0,0 +1,8 @@ +"use strict"; +exports.__esModule = true; +exports.lib = void 0; +exports.lib = { + one: 1, + two: 2, + three: 3 +}; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/indirect/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/indirect/tsconfig.tsbuildinfo new file mode 100644 index 000000000..db7f79b80 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/indirect/tsconfig.tsbuildinfo @@ -0,0 +1,55 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "./index.ts": { + "version": "28ead8445f54a115ea5f778da4f4f80579fbae42ac6ccc3493626084ed335839", + "signature": "82b9c263edd140802d0afbd57d557b2c41db16c5ad9a744bca8c71ad5b10f66f", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": {}, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/lib/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/lib/index.d.ts new file mode 100644 index 000000000..73d752279 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/lib/index.d.ts @@ -0,0 +1,5 @@ +export declare const lib: { + one: number; + two: number; + three: number; +}; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/lib/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/lib/index.js new file mode 100644 index 000000000..b7785ef20 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/lib/index.js @@ -0,0 +1,8 @@ +"use strict"; +exports.__esModule = true; +exports.lib = void 0; +exports.lib = { + one: 1, + two: 2, + three: 3 +}; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/lib/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/lib/tsconfig.tsbuildinfo new file mode 100644 index 000000000..db7f79b80 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/lib/tsconfig.tsbuildinfo @@ -0,0 +1,55 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "./index.ts": { + "version": "28ead8445f54a115ea5f778da4f4f80579fbae42ac6ccc3493626084ed335839", + "signature": "82b9c263edd140802d0afbd57d557b2c41db16c5ad9a744bca8c71ad5b10f66f", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": {}, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/output.txt new file mode 100644 index 000000000..0c195bfc9 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/output.txt @@ -0,0 +1,19 @@ + Asset Size Chunks Chunk Names + ../common/index.d.ts 42 bytes [emitted] + ../common/index.js 128 bytes [emitted] + ../common/tsconfig.tsbuildinfo 2.32 KiB [emitted] + ../indirect/index.d.ts 84 bytes [emitted] + ../indirect/index.js 119 bytes [emitted] +../indirect/tsconfig.tsbuildinfo 2.32 KiB [emitted] + ../lib/index.d.ts 84 bytes [emitted] + ../lib/index.js 119 bytes [emitted] + ../lib/tsconfig.tsbuildinfo 2.32 KiB [emitted] + ../utils/index.d.ts 39 bytes [emitted] + ../utils/index.js 169 bytes [emitted] + ../utils/tsconfig.tsbuildinfo 2.66 KiB [emitted] + bundle.js 5.48 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 41 bytes {main} [built] +[../lib/index.ts] 55 bytes {main} [built] +[../utils/index.ts] 169 bytes {main} [built] +[./app.ts] 184 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/app/bundle.js new file mode 100644 index 000000000..1952eb33b --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/common/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/common/index.d.ts new file mode 100644 index 000000000..78cb4cd49 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/common/index.d.ts @@ -0,0 +1 @@ +export declare function common(): number; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/common/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/common/index.js new file mode 100644 index 000000000..4fafb1dd0 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/common/index.js @@ -0,0 +1,7 @@ +"use strict"; +exports.__esModule = true; +exports.common = void 0; +function common() { + return 35; +} +exports.common = common; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/common/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/common/tsconfig.tsbuildinfo new file mode 100644 index 000000000..4ff9d016e --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/common/tsconfig.tsbuildinfo @@ -0,0 +1,55 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "./index.ts": { + "version": "ea4f1fab5d827d59b4b09d9e42b615faf16b08c259290b9fcb5982bb9543bd52", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": {}, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/output.txt new file mode 100644 index 000000000..6fd7eb1b6 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch0/output.txt @@ -0,0 +1,10 @@ + Asset Size Chunks Chunk Names + ../common/index.d.ts 42 bytes [emitted] + ../common/index.js 128 bytes [emitted] +../common/tsconfig.tsbuildinfo 2.32 KiB [emitted] + bundle.js 5.29 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 128 bytes {main} [built] +[../lib/index.ts] 119 bytes {main} +[../utils/index.ts] 169 bytes {main} [built] +[./app.ts] 184 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/app/bundle.js new file mode 100644 index 000000000..b005a7d9d --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/output.txt new file mode 100644 index 000000000..275922343 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/output.txt @@ -0,0 +1,10 @@ + Asset Size Chunks Chunk Names + ../utils/index.d.ts 81 bytes [emitted] + ../utils/index.js 249 bytes [emitted] +../utils/tsconfig.tsbuildinfo 2.66 KiB [emitted] + bundle.js 5.57 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 41 bytes {main} +[../lib/index.ts] 55 bytes {main} +[../utils/index.ts] 249 bytes {main} [built] +[./app.ts] 184 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/utils/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/utils/index.d.ts new file mode 100644 index 000000000..6ab3917bc --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/utils/index.d.ts @@ -0,0 +1,2 @@ +export declare function utils(): void; +export declare function utils2(): string; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/utils/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/utils/index.js new file mode 100644 index 000000000..2ebba61c6 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/utils/index.js @@ -0,0 +1,10 @@ +"use strict"; +exports.__esModule = true; +exports.utils2 = exports.utils = void 0; +var common_1 = require("../common"); +function utils() { + common_1.common(); +} +exports.utils = utils; +function utils2() { return "hello"; } +exports.utils2 = utils2; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/utils/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/utils/tsconfig.tsbuildinfo new file mode 100644 index 000000000..6d66903d8 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch1/utils/tsconfig.tsbuildinfo @@ -0,0 +1,65 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "../common/index.d.ts": { + "version": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + }, + "./index.ts": { + "version": "a1dbdf6843733c9641c0dccfc0fd2ac2bc4cb630b60143672e64e0a65a8dbb7a", + "signature": "965912a69421fffc4b79247cd826f3e8bdb5cdbd3ab8d0b5ca57e5a40cfc5869", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": { + "./index.ts": [ + "../common/index.d.ts" + ] + }, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "../common/index.d.ts", + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch2/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch2/app/bundle.js new file mode 100644 index 000000000..fa5a91bbf --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch2/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\nutils_1.utils2();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch2/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch2/output.txt new file mode 100644 index 000000000..2b17e5ae9 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch2/output.txt @@ -0,0 +1,7 @@ + Asset Size Chunks Chunk Names +bundle.js 5.58 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 41 bytes {main} +[../lib/index.ts] 55 bytes {main} +[../utils/index.ts] 249 bytes {main} +[./app.ts] 202 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch3/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch3/app/bundle.js new file mode 100644 index 000000000..fa5a91bbf --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch3/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\nutils_1.utils2();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch3/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch3/output.txt new file mode 100644 index 000000000..a6e9e262b --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch3/output.txt @@ -0,0 +1,12 @@ + Asset Size Chunks Chunk Names +bundle.js 5.39 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 128 bytes {main} [built] [1 error] +[../lib/index.ts] 119 bytes {main} +[../utils/index.ts] 249 bytes {main} [built] +[./app.ts] 202 bytes {main} [built] + +ERROR in common\index.ts +../common/index.ts +[tsl] ERROR in common\index.ts(2,3) + TS2322: Type '35' is not assignable to type 'string'. \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/app/bundle.js new file mode 100644 index 000000000..fa5a91bbf --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\nutils_1.utils2();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/common/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/common/index.d.ts new file mode 100644 index 000000000..78cb4cd49 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/common/index.d.ts @@ -0,0 +1 @@ +export declare function common(): number; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/common/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/common/index.js new file mode 100644 index 000000000..4fafb1dd0 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/common/index.js @@ -0,0 +1,7 @@ +"use strict"; +exports.__esModule = true; +exports.common = void 0; +function common() { + return 35; +} +exports.common = common; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/common/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/common/tsconfig.tsbuildinfo new file mode 100644 index 000000000..4ff9d016e --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/common/tsconfig.tsbuildinfo @@ -0,0 +1,55 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "./index.ts": { + "version": "ea4f1fab5d827d59b4b09d9e42b615faf16b08c259290b9fcb5982bb9543bd52", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": {}, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/output.txt new file mode 100644 index 000000000..9a0bbe11c --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch4/output.txt @@ -0,0 +1,10 @@ + Asset Size Chunks Chunk Names + ../common/index.d.ts 42 bytes [emitted] + ../common/index.js 128 bytes [emitted] +../common/tsconfig.tsbuildinfo 2.32 KiB [emitted] + bundle.js 5.39 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 128 bytes {main} [built] +[../lib/index.ts] 119 bytes {main} +[../utils/index.ts] 249 bytes {main} [built] +[./app.ts] 202 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch5/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch5/app/bundle.js new file mode 100644 index 000000000..fa5a91bbf --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch5/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\nutils_1.utils2();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch5/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch5/output.txt new file mode 100644 index 000000000..383bf8626 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch5/output.txt @@ -0,0 +1,12 @@ + Asset Size Chunks Chunk Names +bundle.js 5.39 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 128 bytes {main} +[../lib/index.ts] 119 bytes {main} +[../utils/index.ts] 249 bytes {main} [built] [1 error] +[./app.ts] 202 bytes {main} [built] + +ERROR in utils\index.ts +../utils/index.ts +[tsl] ERROR in utils\index.ts(5,36) + TS2322: Type '"hello"' is not assignable to type 'number'. \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/app/bundle.js new file mode 100644 index 000000000..fa5a91bbf --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\nutils_1.utils2();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/output.txt new file mode 100644 index 000000000..4a30e8107 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/output.txt @@ -0,0 +1,10 @@ + Asset Size Chunks Chunk Names + ../utils/index.d.ts 81 bytes [emitted] + ../utils/index.js 249 bytes [emitted] +../utils/tsconfig.tsbuildinfo 2.66 KiB [emitted] + bundle.js 5.58 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 41 bytes {main} +[../lib/index.ts] 55 bytes {main} +[../utils/index.ts] 249 bytes {main} [built] +[./app.ts] 202 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/utils/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/utils/index.d.ts new file mode 100644 index 000000000..6ab3917bc --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/utils/index.d.ts @@ -0,0 +1,2 @@ +export declare function utils(): void; +export declare function utils2(): string; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/utils/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/utils/index.js new file mode 100644 index 000000000..2ebba61c6 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/utils/index.js @@ -0,0 +1,10 @@ +"use strict"; +exports.__esModule = true; +exports.utils2 = exports.utils = void 0; +var common_1 = require("../common"); +function utils() { + common_1.common(); +} +exports.utils = utils; +function utils2() { return "hello"; } +exports.utils2 = utils2; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/utils/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/utils/tsconfig.tsbuildinfo new file mode 100644 index 000000000..6d66903d8 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/patch6/utils/tsconfig.tsbuildinfo @@ -0,0 +1,65 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "../common/index.d.ts": { + "version": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + }, + "./index.ts": { + "version": "a1dbdf6843733c9641c0dccfc0fd2ac2bc4cb630b60143672e64e0a65a8dbb7a", + "signature": "965912a69421fffc4b79247cd826f3e8bdb5cdbd3ab8d0b5ca57e5a40cfc5869", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": { + "./index.ts": [ + "../common/index.d.ts" + ] + }, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "../common/index.d.ts", + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/utils/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/utils/index.d.ts new file mode 100644 index 000000000..590545c75 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/utils/index.d.ts @@ -0,0 +1 @@ +export declare function utils(): void; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/utils/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/utils/index.js new file mode 100644 index 000000000..7cde7e732 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/utils/index.js @@ -0,0 +1,8 @@ +"use strict"; +exports.__esModule = true; +exports.utils = void 0; +var common_1 = require("../common"); +function utils() { + common_1.common(); +} +exports.utils = utils; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/utils/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/utils/tsconfig.tsbuildinfo new file mode 100644 index 000000000..9302ddcb9 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-3.9/utils/tsconfig.tsbuildinfo @@ -0,0 +1,65 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "../common/index.d.ts": { + "version": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + }, + "./index.ts": { + "version": "4c7e50bd7f85cc5d64f963157685ca8eb1223e12466f47c719aaf1af32173088", + "signature": "2c471583ee40dd55eed961a2de47a5014f6639fa90572027eec9139c40293e19", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": { + "./index.ts": [ + "../common/index.d.ts" + ] + }, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "../common/index.d.ts", + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/app/bundle.js new file mode 100644 index 000000000..d8c5605b7 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 30;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/common/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/common/index.d.ts new file mode 100644 index 000000000..78cb4cd49 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/common/index.d.ts @@ -0,0 +1 @@ +export declare function common(): number; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/common/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/common/index.js new file mode 100644 index 000000000..c561b2cc0 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/common/index.js @@ -0,0 +1,7 @@ +"use strict"; +exports.__esModule = true; +exports.common = void 0; +function common() { + return 30; +} +exports.common = common; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/common/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/common/tsconfig.tsbuildinfo new file mode 100644 index 000000000..3fc50b166 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/common/tsconfig.tsbuildinfo @@ -0,0 +1,55 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "./index.ts": { + "version": "83a8bcfe78ca61ceac765c205ef0435e93f65e7bc386ea12d21e0c963a7e824e", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": {}, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/indirect/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/indirect/index.d.ts new file mode 100644 index 000000000..73d752279 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/indirect/index.d.ts @@ -0,0 +1,5 @@ +export declare const lib: { + one: number; + two: number; + three: number; +}; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/indirect/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/indirect/index.js new file mode 100644 index 000000000..b7785ef20 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/indirect/index.js @@ -0,0 +1,8 @@ +"use strict"; +exports.__esModule = true; +exports.lib = void 0; +exports.lib = { + one: 1, + two: 2, + three: 3 +}; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/indirect/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/indirect/tsconfig.tsbuildinfo new file mode 100644 index 000000000..db7f79b80 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/indirect/tsconfig.tsbuildinfo @@ -0,0 +1,55 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "./index.ts": { + "version": "28ead8445f54a115ea5f778da4f4f80579fbae42ac6ccc3493626084ed335839", + "signature": "82b9c263edd140802d0afbd57d557b2c41db16c5ad9a744bca8c71ad5b10f66f", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": {}, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/lib/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/lib/index.d.ts new file mode 100644 index 000000000..73d752279 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/lib/index.d.ts @@ -0,0 +1,5 @@ +export declare const lib: { + one: number; + two: number; + three: number; +}; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/lib/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/lib/index.js new file mode 100644 index 000000000..b7785ef20 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/lib/index.js @@ -0,0 +1,8 @@ +"use strict"; +exports.__esModule = true; +exports.lib = void 0; +exports.lib = { + one: 1, + two: 2, + three: 3 +}; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/lib/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/lib/tsconfig.tsbuildinfo new file mode 100644 index 000000000..db7f79b80 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/lib/tsconfig.tsbuildinfo @@ -0,0 +1,55 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "./index.ts": { + "version": "28ead8445f54a115ea5f778da4f4f80579fbae42ac6ccc3493626084ed335839", + "signature": "82b9c263edd140802d0afbd57d557b2c41db16c5ad9a744bca8c71ad5b10f66f", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": {}, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/output.txt new file mode 100644 index 000000000..717e4dcce --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/output.txt @@ -0,0 +1,19 @@ + Asset Size Chunks Chunk Names + ../common/index.d.ts 42 bytes [emitted] + ../common/index.js 128 bytes [emitted] + ../common/tsconfig.tsbuildinfo 2.32 KiB [emitted] + ../indirect/index.d.ts 84 bytes [emitted] + ../indirect/index.js 119 bytes [emitted] +../indirect/tsconfig.tsbuildinfo 2.32 KiB [emitted] + ../lib/index.d.ts 84 bytes [emitted] + ../lib/index.js 119 bytes [emitted] + ../lib/tsconfig.tsbuildinfo 2.32 KiB [emitted] + ../utils/index.d.ts 39 bytes [emitted] + ../utils/index.js 169 bytes [emitted] + ../utils/tsconfig.tsbuildinfo 2.66 KiB [emitted] + bundle.js 5.56 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 41 bytes {main} [built] +[../lib/index.ts] 55 bytes {main} [built] +[../utils/index.ts] 205 bytes {main} [built] +[./app.ts] 220 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/app/bundle.js new file mode 100644 index 000000000..d125d00b2 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/common/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/common/index.d.ts new file mode 100644 index 000000000..78cb4cd49 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/common/index.d.ts @@ -0,0 +1 @@ +export declare function common(): number; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/common/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/common/index.js new file mode 100644 index 000000000..4fafb1dd0 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/common/index.js @@ -0,0 +1,7 @@ +"use strict"; +exports.__esModule = true; +exports.common = void 0; +function common() { + return 35; +} +exports.common = common; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/common/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/common/tsconfig.tsbuildinfo new file mode 100644 index 000000000..4ff9d016e --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/common/tsconfig.tsbuildinfo @@ -0,0 +1,55 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "./index.ts": { + "version": "ea4f1fab5d827d59b4b09d9e42b615faf16b08c259290b9fcb5982bb9543bd52", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": {}, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/output.txt new file mode 100644 index 000000000..badfe6b4e --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch0/output.txt @@ -0,0 +1,10 @@ + Asset Size Chunks Chunk Names + ../common/index.d.ts 42 bytes [emitted] + ../common/index.js 128 bytes [emitted] +../common/tsconfig.tsbuildinfo 2.32 KiB [emitted] + bundle.js 5.56 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 41 bytes {main} [built] +[../lib/index.ts] 55 bytes {main} +[../utils/index.ts] 205 bytes {main} [built] +[./app.ts] 220 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/app/bundle.js new file mode 100644 index 000000000..242b1aa29 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/output.txt new file mode 100644 index 000000000..721b3f49a --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/output.txt @@ -0,0 +1,10 @@ + Asset Size Chunks Chunk Names + ../utils/index.d.ts 81 bytes [emitted] + ../utils/index.js 249 bytes [emitted] +../utils/tsconfig.tsbuildinfo 2.66 KiB [emitted] + bundle.js 5.64 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 41 bytes {main} +[../lib/index.ts] 55 bytes {main} +[../utils/index.ts] 285 bytes {main} [built] +[./app.ts] 220 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/utils/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/utils/index.d.ts new file mode 100644 index 000000000..6ab3917bc --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/utils/index.d.ts @@ -0,0 +1,2 @@ +export declare function utils(): void; +export declare function utils2(): string; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/utils/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/utils/index.js new file mode 100644 index 000000000..2ebba61c6 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/utils/index.js @@ -0,0 +1,10 @@ +"use strict"; +exports.__esModule = true; +exports.utils2 = exports.utils = void 0; +var common_1 = require("../common"); +function utils() { + common_1.common(); +} +exports.utils = utils; +function utils2() { return "hello"; } +exports.utils2 = utils2; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/utils/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/utils/tsconfig.tsbuildinfo new file mode 100644 index 000000000..6d66903d8 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch1/utils/tsconfig.tsbuildinfo @@ -0,0 +1,65 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "../common/index.d.ts": { + "version": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + }, + "./index.ts": { + "version": "a1dbdf6843733c9641c0dccfc0fd2ac2bc4cb630b60143672e64e0a65a8dbb7a", + "signature": "965912a69421fffc4b79247cd826f3e8bdb5cdbd3ab8d0b5ca57e5a40cfc5869", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": { + "./index.ts": [ + "../common/index.d.ts" + ] + }, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "../common/index.d.ts", + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch2/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch2/app/bundle.js new file mode 100644 index 000000000..488ec7463 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch2/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\nutils_1.utils2();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch2/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch2/output.txt new file mode 100644 index 000000000..b305b4815 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch2/output.txt @@ -0,0 +1,7 @@ + Asset Size Chunks Chunk Names +bundle.js 5.66 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 41 bytes {main} +[../lib/index.ts] 55 bytes {main} +[../utils/index.ts] 285 bytes {main} +[./app.ts] 238 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch3/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch3/app/bundle.js new file mode 100644 index 000000000..488ec7463 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch3/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\nutils_1.utils2();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch3/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch3/output.txt new file mode 100644 index 000000000..3e7cbb200 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch3/output.txt @@ -0,0 +1,10 @@ + Asset Size Chunks Chunk Names +bundle.js 5.43 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 128 bytes {main} [built] +[../lib/index.ts] 119 bytes {main} +[../utils/index.ts] 249 bytes {main} [built] +[./app.ts] 238 bytes {main} [built] [1 error] + +ERROR in [tsl] ERROR in common\index.ts(2,3) + TS2322: Type '35' is not assignable to type 'string'. \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/app/bundle.js new file mode 100644 index 000000000..488ec7463 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\nutils_1.utils2();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/common/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/common/index.d.ts new file mode 100644 index 000000000..78cb4cd49 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/common/index.d.ts @@ -0,0 +1 @@ +export declare function common(): number; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/common/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/common/index.js new file mode 100644 index 000000000..4fafb1dd0 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/common/index.js @@ -0,0 +1,7 @@ +"use strict"; +exports.__esModule = true; +exports.common = void 0; +function common() { + return 35; +} +exports.common = common; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/common/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/common/tsconfig.tsbuildinfo new file mode 100644 index 000000000..4ff9d016e --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/common/tsconfig.tsbuildinfo @@ -0,0 +1,55 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "./index.ts": { + "version": "ea4f1fab5d827d59b4b09d9e42b615faf16b08c259290b9fcb5982bb9543bd52", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": {}, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/output.txt new file mode 100644 index 000000000..02ddcb4a5 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch4/output.txt @@ -0,0 +1,10 @@ + Asset Size Chunks Chunk Names + ../common/index.d.ts 42 bytes [emitted] + ../common/index.js 128 bytes [emitted] +../common/tsconfig.tsbuildinfo 2.32 KiB [emitted] + bundle.js 5.66 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 41 bytes {main} [built] +[../lib/index.ts] 55 bytes {main} +[../utils/index.ts] 285 bytes {main} [built] +[./app.ts] 238 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch5/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch5/app/bundle.js new file mode 100644 index 000000000..488ec7463 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch5/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\nutils_1.utils2();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch5/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch5/output.txt new file mode 100644 index 000000000..907833e71 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch5/output.txt @@ -0,0 +1,10 @@ + Asset Size Chunks Chunk Names +bundle.js 5.66 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 41 bytes {main} +[../lib/index.ts] 55 bytes {main} +[../utils/index.ts] 285 bytes {main} [built] +[./app.ts] 238 bytes {main} [built] [1 error] + +ERROR in [tsl] ERROR in utils\index.ts(5,36) + TS2322: Type '"hello"' is not assignable to type 'number'. \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/app/bundle.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/app/bundle.js new file mode 100644 index 000000000..488ec7463 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/app/bundle.js @@ -0,0 +1,137 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = "./app.ts"); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "../common/index.ts": +/*!**************************!*\ + !*** ../common/index.ts ***! + \**************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.common = void 0;\nfunction common() {\n return 35;\n}\nexports.common = common;\n\n\n//# sourceURL=webpack:///../common/index.ts?"); + +/***/ }), + +/***/ "../lib/index.ts": +/*!***********************!*\ + !*** ../lib/index.ts ***! + \***********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.lib = void 0;\nexports.lib = {\n one: 1,\n two: 2,\n three: 3\n};\n\n\n//# sourceURL=webpack:///../lib/index.ts?"); + +/***/ }), + +/***/ "../utils/index.ts": +/*!*************************!*\ + !*** ../utils/index.ts ***! + \*************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nexports.__esModule = true;\nexports.utils2 = exports.utils = void 0;\nvar common_1 = __webpack_require__(/*! ../common */ \"../common/index.ts\");\nfunction utils() {\n common_1.common();\n}\nexports.utils = utils;\nfunction utils2() { return \"hello\"; }\nexports.utils2 = utils2;\n\n\n//# sourceURL=webpack:///../utils/index.ts?"); + +/***/ }), + +/***/ "./app.ts": +/*!****************!*\ + !*** ./app.ts ***! + \****************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval("\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar lib_1 = __webpack_require__(/*! ../lib */ \"../lib/index.ts\");\nvar utils_1 = __webpack_require__(/*! ../utils */ \"../utils/index.ts\");\nconsole.log(lib_1.lib.one, lib_1.lib.two, lib_1.lib.three);\nutils_1.utils();\nutils_1.utils2();\n\n\n//# sourceURL=webpack:///./app.ts?"); + +/***/ }) + +/******/ }); \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/output.txt b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/output.txt new file mode 100644 index 000000000..b34c6bb44 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/output.txt @@ -0,0 +1,10 @@ + Asset Size Chunks Chunk Names + ../utils/index.d.ts 81 bytes [emitted] + ../utils/index.js 249 bytes [emitted] +../utils/tsconfig.tsbuildinfo 2.66 KiB [emitted] + bundle.js 5.66 KiB main [emitted] main +Entrypoint main = bundle.js +[../common/index.ts] 41 bytes {main} +[../lib/index.ts] 55 bytes {main} +[../utils/index.ts] 285 bytes {main} [built] +[./app.ts] 238 bytes {main} [built] \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/utils/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/utils/index.d.ts new file mode 100644 index 000000000..6ab3917bc --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/utils/index.d.ts @@ -0,0 +1,2 @@ +export declare function utils(): void; +export declare function utils2(): string; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/utils/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/utils/index.js new file mode 100644 index 000000000..2ebba61c6 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/utils/index.js @@ -0,0 +1,10 @@ +"use strict"; +exports.__esModule = true; +exports.utils2 = exports.utils = void 0; +var common_1 = require("../common"); +function utils() { + common_1.common(); +} +exports.utils = utils; +function utils2() { return "hello"; } +exports.utils2 = utils2; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/utils/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/utils/tsconfig.tsbuildinfo new file mode 100644 index 000000000..6d66903d8 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/patch6/utils/tsconfig.tsbuildinfo @@ -0,0 +1,65 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "../common/index.d.ts": { + "version": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + }, + "./index.ts": { + "version": "a1dbdf6843733c9641c0dccfc0fd2ac2bc4cb630b60143672e64e0a65a8dbb7a", + "signature": "965912a69421fffc4b79247cd826f3e8bdb5cdbd3ab8d0b5ca57e5a40cfc5869", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": { + "./index.ts": [ + "../common/index.d.ts" + ] + }, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "../common/index.d.ts", + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/utils/index.d.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/utils/index.d.ts new file mode 100644 index 000000000..590545c75 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/utils/index.d.ts @@ -0,0 +1 @@ +export declare function utils(): void; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/utils/index.js b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/utils/index.js new file mode 100644 index 000000000..7cde7e732 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/utils/index.js @@ -0,0 +1,8 @@ +"use strict"; +exports.__esModule = true; +exports.utils = void 0; +var common_1 = require("../common"); +function utils() { + common_1.common(); +} +exports.utils = utils; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/utils/tsconfig.tsbuildinfo b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/utils/tsconfig.tsbuildinfo new file mode 100644 index 000000000..9302ddcb9 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/expectedOutput-transpile-3.9/utils/tsconfig.tsbuildinfo @@ -0,0 +1,65 @@ +{ + "program": { + "fileInfos": { + "../../../node_modules/typescript/lib/lib.d.ts": { + "version": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "signature": "2dc8c927c9c162a773c6bb3cdc4f3286c23f10eedc67414028f9cb5951610f60", + "affectsGlobalScope": false + }, + "../../../node_modules/typescript/lib/lib.es5.d.ts": { + "version": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "signature": "70ae6416528e68c2ee7b62892200d2ca631759943d4429f8b779b947ff1e124d", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.dom.d.ts": { + "version": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "signature": "9affb0a2ddc57df5b8174c0af96c288d697a262e5bc9ca1f544c999dc64a91e6", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts": { + "version": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "signature": "7fac8cb5fc820bc2a59ae11ef1c5b38d3832c6d0dfaec5acdb5569137d09a481", + "affectsGlobalScope": true + }, + "../../../node_modules/typescript/lib/lib.scripthost.d.ts": { + "version": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "signature": "097a57355ded99c68e6df1b738990448e0bf170e606707df5a7c0481ff2427cd", + "affectsGlobalScope": true + }, + "../common/index.d.ts": { + "version": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "signature": "43a7b48da056d56d751b52b1b22e1445fe52b56355f0adcbfd52c12ddc3e3ecb", + "affectsGlobalScope": false + }, + "./index.ts": { + "version": "4c7e50bd7f85cc5d64f963157685ca8eb1223e12466f47c719aaf1af32173088", + "signature": "2c471583ee40dd55eed961a2de47a5014f6639fa90572027eec9139c40293e19", + "affectsGlobalScope": false + } + }, + "options": { + "composite": true, + "types": [], + "newLine": 1, + "configFilePath": "./tsconfig.json", + "skipLibCheck": true, + "suppressOutputPathCheck": true + }, + "referencedMap": { + "./index.ts": [ + "../common/index.d.ts" + ] + }, + "exportedModulesMap": {}, + "semanticDiagnosticsPerFile": [ + "../common/index.d.ts", + "./index.ts", + "../../../node_modules/typescript/lib/lib.d.ts", + "../../../node_modules/typescript/lib/lib.dom.d.ts", + "../../../node_modules/typescript/lib/lib.es5.d.ts", + "../../../node_modules/typescript/lib/lib.scripthost.d.ts", + "../../../node_modules/typescript/lib/lib.webworker.importscripts.d.ts" + ] + }, + "version": "3.9.3" +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/indirect/index.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/indirect/index.ts new file mode 100644 index 000000000..669ca7b3d --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/indirect/index.ts @@ -0,0 +1,5 @@ +export const lib = { + one: 1, + two: 2, + three: 3 +}; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/indirect/tsconfig.json b/test/comparison-tests/projectReferencesMultipleDifferentInstance/indirect/tsconfig.json new file mode 100644 index 000000000..0710dd495 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/indirect/tsconfig.json @@ -0,0 +1,6 @@ +{ + "compilerOptions": { + "composite": true, + "types": [] + } +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/lib/index.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/lib/index.ts new file mode 100644 index 000000000..669ca7b3d --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/lib/index.ts @@ -0,0 +1,5 @@ +export const lib = { + one: 1, + two: 2, + three: 3 +}; diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/lib/tsconfig.json b/test/comparison-tests/projectReferencesMultipleDifferentInstance/lib/tsconfig.json new file mode 100644 index 000000000..0710dd495 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/lib/tsconfig.json @@ -0,0 +1,6 @@ +{ + "compilerOptions": { + "composite": true, + "types": [] + } +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch0/common/index.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch0/common/index.ts new file mode 100644 index 000000000..1fd3fd273 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch0/common/index.ts @@ -0,0 +1,3 @@ +export function common() { + return 35; +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch1/utils/index.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch1/utils/index.ts new file mode 100644 index 000000000..a6d4e6503 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch1/utils/index.ts @@ -0,0 +1,5 @@ +import { common } from "../common"; +export function utils() { + common(); +} +export function utils2() { return "hello"; } \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch2/app/app.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch2/app/app.ts new file mode 100644 index 000000000..d03f46df1 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch2/app/app.ts @@ -0,0 +1,6 @@ +import { lib } from '../lib'; +import { utils, utils2 } from "../utils"; + +console.log(lib.one, lib.two, lib.three); +utils(); +utils2(); diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch3/common/index.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch3/common/index.ts new file mode 100644 index 000000000..a261c48cb --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch3/common/index.ts @@ -0,0 +1,3 @@ +export function common(): string { + return 35; +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch4/common/index.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch4/common/index.ts new file mode 100644 index 000000000..1fd3fd273 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch4/common/index.ts @@ -0,0 +1,3 @@ +export function common() { + return 35; +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch5/utils/index.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch5/utils/index.ts new file mode 100644 index 000000000..e1668e8f5 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch5/utils/index.ts @@ -0,0 +1,5 @@ +import { common } from "../common"; +export function utils() { + common(); +} +export function utils2(): number { return "hello"; } \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch6/utils/index.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch6/utils/index.ts new file mode 100644 index 000000000..a6d4e6503 --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/patch6/utils/index.ts @@ -0,0 +1,5 @@ +import { common } from "../common"; +export function utils() { + common(); +} +export function utils2() { return "hello"; } \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/utils/index.ts b/test/comparison-tests/projectReferencesMultipleDifferentInstance/utils/index.ts new file mode 100644 index 000000000..713ee249d --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/utils/index.ts @@ -0,0 +1,4 @@ +import { common } from "../common"; +export function utils() { + common(); +} \ No newline at end of file diff --git a/test/comparison-tests/projectReferencesMultipleDifferentInstance/utils/tsconfig.json b/test/comparison-tests/projectReferencesMultipleDifferentInstance/utils/tsconfig.json new file mode 100644 index 000000000..232bd996b --- /dev/null +++ b/test/comparison-tests/projectReferencesMultipleDifferentInstance/utils/tsconfig.json @@ -0,0 +1,10 @@ +{ + "compilerOptions": { + "composite": true, + "types": [] + }, + "references": [ + { "path": "../common" }, + { "path": "../indirect" } + ] +} \ No newline at end of file