diff --git a/compiler/src/ark_utils.ts b/compiler/src/ark_utils.ts index 70674432fdf01f43fe3c93809e65f2af7f175686..5a7536a2a31403c5deed18916d58b8df0d2e547a 100644 --- a/compiler/src/ark_utils.ts +++ b/compiler/src/ark_utils.ts @@ -130,8 +130,8 @@ export function getNormalizedOhmUrlByFilepath(filePath: string, projectConfig: O 'Failed to resolve OhmUrl. ' + `Failed to get a resolved OhmUrl for "${filePath}" imported by "${importerFile}".`, '', - [`Check whether the "${pkgName}" module which ${filePath} belongs to is correctly configured.`, - 'Check the corresponding file name is correct(including case-sensitivity).'] + [`Check whether the "${pkgName}" module which ${filePath} belongs to is correctly configured.`, + `Check if the corresponding file name "${filePath}" is correct(including case-sensitivity).`] ); logger.printError(errInfo); return filePath; @@ -230,8 +230,8 @@ function processPackageDir(params: Object): string { 'Failed to resolve OhmUrl. ' + `Failed to get a resolved OhmUrl for "${originalFilePath}" imported by "${importerFile}".`, '', - [`Check whether the module which ${originalFilePath} belongs to is correctly configured.`, - 'Check the corresponding file name is correct(including case-sensitivity).'] + [`Check whether the module which ${originalFilePath} belongs to is correctly configured.`, + `Check if the corresponding file name "${originalFilePath}" is correct(including case-sensitivity).`] ); logger.printError(errInfo); return originalFilePath; @@ -269,8 +269,8 @@ function processPackageDir(params: Object): string { 'Failed to resolve OhmUrl. ' + `Failed to get a resolved OhmUrl for "${originalFilePath}" imported by "${importerFile}".`, '', - [`Check whether the module which ${originalFilePath} belongs to is correctly configured.`, - 'Check the corresponding file name is correct(including case-sensitivity).'] + [`Check whether the module which ${originalFilePath} belongs to is correctly configured.`, + `Check if the corresponding file name "${originalFilePath}" is correct(including case-sensitivity).`] ); logger.printError(errInfo); return originalFilePath; diff --git a/compiler/test/ark_compiler_ut/module/ohmUrl/ohmUrl.test.ts b/compiler/test/ark_compiler_ut/module/ohmUrl/ohmUrl.test.ts index 7f09e32a6af014b4a3401bd9e646a31dc39c8dba..8455fd83a00317c2044ef2e01a35dec637694ba4 100644 --- a/compiler/test/ark_compiler_ut/module/ohmUrl/ohmUrl.test.ts +++ b/compiler/test/ark_compiler_ut/module/ohmUrl/ohmUrl.test.ts @@ -191,7 +191,7 @@ mocha.describe('generate ohmUrl', function () { 'Failed to get a resolved OhmUrl for "/testProjectRootPath/entry/oh_modules/json5/dist/index.js" imported by "importTest.ts".', '', ['Check whether the module which /testProjectRootPath/entry/oh_modules/json5/dist/index.js belongs to is correctly configured.', - 'Check the corresponding file name is correct(including case-sensitivity).'] + 'Check if the corresponding file name "/testProjectRootPath/entry/oh_modules/json5/dist/index.js" is correct(including case-sensitivity).'] ); const logger = CommonLogger.getInstance(this.rollup); const stub = sinon.stub(logger.getLoggerFromErrorCode(errInfo.code), 'printError'); @@ -213,7 +213,7 @@ mocha.describe('generate ohmUrl', function () { 'Failed to get a resolved OhmUrl for "/testProjectRootPath/entry/oh_modules/json5/dist/index.js" imported by "importTest.ts".', '', ['Check whether the module which /testProjectRootPath/entry/oh_modules/json5/dist/index.js belongs to is correctly configured.', - 'Check the corresponding file name is correct(including case-sensitivity).'] + 'Check if the corresponding file name "/testProjectRootPath/entry/oh_modules/json5/dist/index.js" is correct(including case-sensitivity).'] ); CommonLogger.destroyInstance(); const getHvigorConsoleLogger = this.rollup.share.getHvigorConsoleLogger; @@ -241,7 +241,7 @@ mocha.describe('generate ohmUrl', function () { '"/testProjectRootPath/entry/oh_modules/json5/dist/index.js" imported by "importTest.ts".', '', ['Check whether the module which /testProjectRootPath/entry/oh_modules/json5/dist/index.js belongs to is correctly configured.', - 'Check the corresponding file name is correct(including case-sensitivity).'] + 'Check if the corresponding file name "/testProjectRootPath/entry/oh_modules/json5/dist/index.js" is correct(including case-sensitivity).'] ); const logger = CommonLogger.getInstance(this.rollup); const stub = sinon.stub(logger.getLoggerFromErrorCode(errInfo.code), 'printError'); @@ -265,7 +265,7 @@ mocha.describe('generate ohmUrl', function () { '"/testProjectRootPath/entry/oh_modules/json5/dist/index.js" imported by "importTest.ts".', '', ['Check whether the module which /testProjectRootPath/entry/oh_modules/json5/dist/index.js belongs to is correctly configured.', - 'Check the corresponding file name is correct(including case-sensitivity).'] + 'Check if the corresponding file name "/testProjectRootPath/entry/oh_modules/json5/dist/index.js" is correct(including case-sensitivity).'] ); CommonLogger.destroyInstance(); const getHvigorConsoleLogger = this.rollup.share.getHvigorConsoleLogger; @@ -972,7 +972,7 @@ mocha.describe('generate ohmUrl', function () { 'Failed to get a resolved OhmUrl for "/testProjectRootPath/entry/oh_modules/json5/dist/index.js" imported by "importTest.ts".', '', ['Check whether the "json5" module which /testProjectRootPath/entry/oh_modules/json5/dist/index.js belongs to is correctly configured.', - 'Check the corresponding file name is correct(including case-sensitivity).'] + 'Check if the corresponding file name "/testProjectRootPath/entry/oh_modules/json5/dist/index.js" is correct(including case-sensitivity).'] ); const logger = CommonLogger.getInstance(this.rollup); const stub = sinon.stub(logger.getLoggerFromErrorCode(errInfo.code), 'printError'); @@ -1004,7 +1004,7 @@ mocha.describe('generate ohmUrl', function () { 'Failed to get a resolved OhmUrl for "/testProjectRootPath/entry/oh_modules/json5/dist/index.js" imported by "importTest.ts".', '', ['Check whether the "json5" module which /testProjectRootPath/entry/oh_modules/json5/dist/index.js belongs to is correctly configured.', - 'Check the corresponding file name is correct(including case-sensitivity).'] + 'Check if the corresponding file name "/testProjectRootPath/entry/oh_modules/json5/dist/index.js" is correct(including case-sensitivity).'] ); CommonLogger.destroyInstance(); const getHvigorConsoleLogger = this.rollup.share.getHvigorConsoleLogger;