wighawag / hardhat-deploy

hardhat deployment plugin
MIT License
1.18k stars 286 forks source link

`deployFixture` in hre test task ignores tags #388

Open riordant opened 1 year ago

riordant commented 1 year ago

Describe the bug We are running deployments before the test task using the --deploy-fixture feature. Here is the code:

        const tsFiles = glob.sync(path.join(hre.config.paths.tests, "e2e", "**/*.spec.ts"));
        await hre.run("test", { testFiles: [...tsFiles], deployFixture: true, tags: ['test'] });

For the deploy scripts, I have defined tag like so:

func.tags = ["mainnet"];
export default func;

yet this ignores the test tag and deploys these scripts anyway. Not sure if this is something wrong with my setup or actually a bug.

versions

        "hardhat-deploy": "^0.11.2",
         "hardhat": "2.9.2",