UNPKG

solcosm

Version:

Solidity interfaces and inheritable contracts for Cosmos SDK structs, messages and queries

27 lines (22 loc) 1.01 kB
import { time, loadFixture } from "@nomicfoundation/hardhat-network-helpers"; import { anyValue } from "@nomicfoundation/hardhat-chai-matchers/withArgs"; import { expect } from "chai"; import { ethers } from "hardhat"; describe("MyContract", function () { // We define a fixture to reuse the same setup in every test. // We use loadFixture to run this setup once, snapshot that state, // and reset Hardhat Network to that snapshot in every test. async function deployMyContractFixture() { // Contracts are deployed using the first signer/account by default const [owner, otherAccount] = await ethers.getSigners(); const MyContract = await ethers.getContractFactory("MyContract"); const mycontract = await MyContract.deploy(); return { mycontract, owner, otherAccount }; } describe("Deployment", function () { it("Should deploy", async function () { const { mycontract } = await loadFixture(deployMyContractFixture); expect(true).to.equal(true); }); }); });