While exploring the awesome possibilities of testing canisters with Pocket-ic, I noticed that eventually there is a lot of configuration needed to set-up commonly used canisters like for example the ledger canister;
This goes from;
- finding the correct WASM
- looking up the initialize arguments
- navigating through the dfinity/ic repo to find what arguments are required etc.
This step repeats for every similar canister, in my scenario i also needed the CMC canister that also required a governance canister, etc.
Long story short, there is a lot of configuration needed to get a similar setup to mainnet to run tests. Is there any way to do this simpler? Like maybe having an
use_nns_subnet_with_installed_canisters
in pocket ic?
Or maybe something like this is already possible but i missed it?
1 Like
I second this, I noticed too while setting up the NNS subnet and following this guide that there was a lot of configuration and steps required. There is actually a step that requires you to clone the whole IC repo - which seems a bit heavy handed:
I think setting up the NNS subnet with canisters like NNS governance, ICP ledger, CMC etc are some of the most popular types of pocket IC tests? So if the configuration required is simplified it would be awesome. For picjs if I could do something like:
import { createIdentity, pocketIc, NNS, SNS } from "@hadronous/pic";
It would be a dream
2 Likes
The guide you shared did help me fix it! Still pretty time consuming and still needed to reinstall the ledger canister but itβs now possible to run the tests as expected.
Iβm not going to mark it as resolved to see if there might be improvements possible like the one suggested (subnet with installed canisters / state)
1 Like