import { MockDecryptionVerifier__factory as MockDecryptionVerifierFactory, } from "../../types";
import { storeDeploymentArgs } from "../utils";
export const deployAndSaveMockDecryptionVerifier = async (hre) => {
    const { ethers } = await hre.network.connect();
    const [signer] = await ethers.getSigners();
    const chain = hre.globalOptions.network;
    const decryptionVerifierFactory = await ethers.getContractFactory("MockDecryptionVerifier");
    const decryptionVerifier = await decryptionVerifierFactory.deploy();
    await decryptionVerifier.waitForDeployment();
    const decryptionVerifierAddress = await decryptionVerifier.getAddress();
    const blockNumber = await ethers.provider.getBlockNumber();
    storeDeploymentArgs({
        blockNumber,
        address: decryptionVerifierAddress,
    }, "MockDecryptionVerifier", chain);
    const decryptionVerifierContract = MockDecryptionVerifierFactory.connect(decryptionVerifierAddress, signer);
    return { decryptionVerifier: decryptionVerifierContract };
};
