Skip to content

Error: No Contract deployed with name VRFCoordinatorV2Mock #3613

Answered by pacelliv
kihiuFrank asked this question in Q&A
Discussion options

You must be logged in to vote

Your unit test is deploying the script with the tag "randomipfs", but the code in that script is looking for the latest deployment of VRFCoordinatorV2Mock but can't find it because the mock is not being deploying by the test. Including the "mocks" tag should fix this error:

describe("RandomIpfsNft Unit Tests", () => {
          let deployer, randomIpfsNft, vrfCoordinatorV2Mock

          beforeEach("runs before every test", async () => {
              accounts = await ethers.getSigners()
              deployer = accounts[0]
              //   deployer = await getNamedAccounts()
              await deployments.fixture(["mocks", "randomipfs"])
              randomIpfsNft = await ethers.getC…

Replies: 4 comments 5 replies

Comment options

You must be logged in to vote
4 replies
@kihiuFrank
Comment options

@pacelliv
Comment options

@kihiuFrank
Comment options

@pacelliv
Comment options

Answer selected by kihiuFrank
Comment options

You must be logged in to vote
1 reply
@kihiuFrank
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
5 participants