diff --git a/packages/core/src/errors-list.ts b/packages/core/src/errors-list.ts index 4b281b506..622e86c31 100644 --- a/packages/core/src/errors-list.ts +++ b/packages/core/src/errors-list.ts @@ -222,13 +222,15 @@ export const ERRORS = { }, OVERLOAD_NAME_REQUIRED: { number: 710, - message: - "%eventOrFunction% '%name%' is overloaded in contract %contractName%. Please use one of these names instead: %normalizedNameList%", + message: `%eventOrFunction% '%name%' is overloaded in contract %contractName%. Please use one of these names instead: + +%normalizedNameList%`, }, INVALID_OVERLOAD_GIVEN: { number: 711, - message: - "%eventOrFunction% '%name%' is not a valid overload of '%bareName%' in contract %contractName%. Please use one of these names instead: %normalizedNameList%", + message: `%eventOrFunction% '%name%' is not a valid overload of '%bareName%' in contract %contractName%. Please use one of these names instead: + +%normalizedNameList%`, }, EVENT_ARG_NOT_FOUND: { number: 712, diff --git a/packages/core/test/call.ts b/packages/core/test/call.ts index ba9e0c4e2..de3155041 100644 --- a/packages/core/test/call.ts +++ b/packages/core/test/call.ts @@ -534,7 +534,7 @@ describe("call", () => { await assert.isRejected( validateNamedContractCall(future as any, setupMockArtifactResolver()), - /Function "test" not found in contract Another/ + /Function 'test' not found in contract Another/ ); }); diff --git a/packages/core/test/execution/abi.ts b/packages/core/test/execution/abi.ts index e2b658f46..72aa04167 100644 --- a/packages/core/test/execution/abi.ts +++ b/packages/core/test/execution/abi.ts @@ -252,7 +252,7 @@ describe("abi", () => { const artifact = callEncodingFixtures.WithComplexArguments; assert.throws(() => { decodeArtifactFunctionCallResult(artifact, "nonExistent", "0x"); - }, 'Function "nonExistent" not found in contract WithComplexArguments'); + }, "Function 'nonExistent' not found in contract WithComplexArguments"); }); it("Should be able to decode a single successful result", () => { @@ -373,7 +373,7 @@ describe("abi", () => { const artifact = callEncodingFixtures.WithComplexArguments; assert.throws(() => { encodeArtifactFunctionCall(artifact, "nonExistent", []); - }, 'Function "nonExistent" not found in contract WithComplexArguments'); + }, "Function 'nonExistent' not found in contract WithComplexArguments"); }); it("Should encode the arguments and return them", () => { @@ -651,7 +651,7 @@ describe("abi", () => { callEncodingFixtures.FunctionNameValidation, "12" ), - `Invalid function name "12"` + `Invalid function name '12'` ); assert.throws( @@ -660,7 +660,7 @@ describe("abi", () => { callEncodingFixtures.FunctionNameValidation, "asd(123, asd" ), - `Invalid function name "asd(123, asd"` + `Invalid function name 'asd(123, asd'` ); }); @@ -671,7 +671,7 @@ describe("abi", () => { callEncodingFixtures.FunctionNameValidation, "nonExistentFunction" ), - `Function "nonExistentFunction" not found in contract FunctionNameValidation` + `Function 'nonExistentFunction' not found in contract FunctionNameValidation` ); assert.throws( @@ -680,7 +680,7 @@ describe("abi", () => { callEncodingFixtures.FunctionNameValidation, "nonExistentFunction2(uint,bytes32)" ), - `Function "nonExistentFunction2(uint,bytes32)" not found in contract FunctionNameValidation` + `Function 'nonExistentFunction2(uint,bytes32)' not found in contract FunctionNameValidation` ); }); @@ -708,7 +708,7 @@ describe("abi", () => { callEncodingFixtures.FunctionNameValidation, "noOverloads()" ); - }, `Function name "noOverloads()" used for contract FunctionNameValidation, but it's not overloaded. Use "noOverloads" instead`); + }, `Function name 'noOverloads()' used for contract FunctionNameValidation, but it's not overloaded. Use 'noOverloads' instead`); }); }); @@ -721,7 +721,7 @@ describe("abi", () => { "withTypeBasedOverloads" ); }, - `Function "withTypeBasedOverloads" is overloaded in contract FunctionNameValidation. Please use one of these names instead: + `Function 'withTypeBasedOverloads' is overloaded in contract FunctionNameValidation. Please use one of these names instead: * withTypeBasedOverloads(uint256) * withTypeBasedOverloads(int256)` @@ -734,7 +734,7 @@ describe("abi", () => { "withParamCountOverloads" ); }, - `Function "withParamCountOverloads" is overloaded in contract FunctionNameValidation. Please use one of these names instead: + `Function 'withParamCountOverloads' is overloaded in contract FunctionNameValidation. Please use one of these names instead: * withParamCountOverloads() * withParamCountOverloads(int256)` @@ -749,7 +749,7 @@ describe("abi", () => { "withTypeBasedOverloads(bool)" ); }, - `Function "withTypeBasedOverloads(bool)" is not a valid overload of "withTypeBasedOverloads" in contract FunctionNameValidation. Please use one of these names instead: + `Function 'withTypeBasedOverloads(bool)' is not a valid overload of 'withTypeBasedOverloads' in contract FunctionNameValidation. Please use one of these names instead: * withTypeBasedOverloads(uint256) * withTypeBasedOverloads(int256)` @@ -762,7 +762,7 @@ describe("abi", () => { "withParamCountOverloads(bool)" ); }, - `Function "withParamCountOverloads(bool)" is not a valid overload of "withParamCountOverloads" in contract FunctionNameValidation. Please use one of these names instead: + `Function 'withParamCountOverloads(bool)' is not a valid overload of 'withParamCountOverloads' in contract FunctionNameValidation. Please use one of these names instead: * withParamCountOverloads() * withParamCountOverloads(int256)` diff --git a/packages/core/test/execution/libraries.ts b/packages/core/test/execution/libraries.ts index a87ab366c..51708fc3e 100644 --- a/packages/core/test/execution/libraries.ts +++ b/packages/core/test/execution/libraries.ts @@ -59,7 +59,7 @@ describe("Libraries handling", () => { "Lib", "contracts/C.sol:Lib", ]); - }, `The names "contracts/C.sol:Lib" and "Lib" clash with each other`); + }, `The names 'contracts/C.sol:Lib' and 'Lib' clash with each other`); }); it("Should accept bare names if non-ambiguous", () => { diff --git a/packages/core/test/readEventArgument.ts b/packages/core/test/readEventArgument.ts index 536b45794..391c713a2 100644 --- a/packages/core/test/readEventArgument.ts +++ b/packages/core/test/readEventArgument.ts @@ -275,7 +275,7 @@ describe("Read event argument", () => { await assert.isRejected( validateReadEventArgument(future as any, setupMockArtifactResolver()), - /Event "test" not found/ + /Event 'test' not found/ ); }); }); diff --git a/packages/core/test/staticCall.ts b/packages/core/test/staticCall.ts index 6d24f7846..54625fea9 100644 --- a/packages/core/test/staticCall.ts +++ b/packages/core/test/staticCall.ts @@ -549,7 +549,7 @@ describe("static call", () => { await assert.isRejected( validateNamedStaticCall(future as any, setupMockArtifactResolver()), - /Function "test" not found in contract Another/ + /Function 'test' not found in contract Another/ ); }); diff --git a/packages/core/test/useModule.ts b/packages/core/test/useModule.ts index 5b57757f0..4ed7a6d27 100644 --- a/packages/core/test/useModule.ts +++ b/packages/core/test/useModule.ts @@ -212,7 +212,7 @@ describe("useModule", () => { type: DeploymentResultType.VALIDATION_ERROR, errors: { "Submodule1#Contract1": [ - "Module parameter 'param1' requires a value but was given none", + "IGN725: Module parameter 'param1' requires a value but was given none", ], }, }); diff --git a/packages/core/test/wipe.ts b/packages/core/test/wipe.ts index 90a017950..f8d049741 100644 --- a/packages/core/test/wipe.ts +++ b/packages/core/test/wipe.ts @@ -134,7 +134,7 @@ describe("wipe", () => { await assert.isRejected( wiper.wipe(contract1Id), - `Cannot wipe ${contract1Id} as there are dependent futures that have already started:\n ${contract2Id}` + `Cannot wipe ${contract1Id} as there are dependent futures that have already started: ${contract2Id}` ); }); });