f95e9a7d37
- This will need to be separated and configured accordingly - This was a quick spin up, using jest as a library to implement some coverage - Further things to be refined - mocks, more coverage, better configuration, clean up methods, improve env vars
20 lines
755 B
TypeScript
20 lines
755 B
TypeScript
import validator from "../../src/index";
|
|
import { config } from '../test-utils/config';
|
|
|
|
const NETWORK_DENOM = config.CURRENCY_PREFIX as string;
|
|
|
|
describe("perform basic interactions with the validator", () => {
|
|
test("build client and get all mixnodes", async () => {
|
|
const mnemonic = validator.randomMnemonic();
|
|
const mnemonicCount = mnemonic.split(" ").length;
|
|
expect(mnemonicCount).toStrictEqual(24);
|
|
});
|
|
|
|
test("build client and get all mixnodes", async () => {
|
|
const buildMnemonic = validator.randomMnemonic();
|
|
const mnemonic = await validator.mnemonicToAddress(buildMnemonic, NETWORK_DENOM);
|
|
expect(mnemonic).toHaveLength(43);
|
|
expect(mnemonic).toContain(NETWORK_DENOM);
|
|
});
|
|
});
|