Ignore specific warnings and make the rest into errors (#3695)

(cherry picked from commit 046121e080)
This commit is contained in:
Francisco
2022-09-22 17:33:13 -03:00
committed by Francisco Giordano
parent 8740d8f7f3
commit 089f9b95af
7 changed files with 490 additions and 58 deletions

View File

@ -50,6 +50,7 @@ const argv = require('yargs/yargs')()
.argv;
require('@nomiclabs/hardhat-truffle5');
require('hardhat-ignore-warnings');
if (argv.gas) {
require('hardhat-gas-reporter');
@ -75,6 +76,13 @@ module.exports = {
viaIR: withOptimizations && argv.ir,
},
},
warnings: {
'*': {
'code-size': withOptimizations,
'unused-param': !argv.coverage, // coverage causes unused-param warnings
default: 'error',
},
},
networks: {
hardhat: {
blockGasLimit: 10000000,