E2E testing for dApps using Puppeteer + Nexus
open nexus extension page, get hello nexus message
const nexusExtensionPath = "./build"
const browser = await launchWithNexus(
{nexusPath: nexusExtensionPath}
)
const nexusWallet = await setUpNexus(browser, {mock: true})
const newPage = await nexusWallet.popup.getNewPage();
let res1 = await nexusWallet.popup.getHelloNexus(newPage);
expect(res1).to.be.include("Hello Nexus")nexus methods
export type NexusWallet = {
popup: PopupPageHelper;
getNotificationPage: () => Promise<Page>
close: () => void
}run test after start e2e-web
npm i
npm run test