Skip to content

Commit

Permalink
fix: fix icon-archway e2e demo script
Browse files Browse the repository at this point in the history
  • Loading branch information
hemz10 committed Dec 15, 2023
1 parent b85b5dd commit ca09b36
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions test/scripts/cosmos/helper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,15 @@ import { GasPrice, SigningStargateClient } from "@cosmjs/stargate";
import { exec } from "child_process";
import fs from "fs";
import { Secp256k1HdWallet } from "@cosmjs/launchpad";
import { SigningCosmWasmClient } from "@cosmjs/cosmwasm-stargate";

const defaultGasPrice = GasPrice.fromString("0stake");

export async function CreateSigningClient(
mnemonic: string,
prefix: string,
endpoint: string
): Promise<[SigningStargateClient, string]> {
): Promise<[SigningCosmWasmClient, string]> {

const wallet = await Secp256k1HdWallet.fromMnemonic(mnemonic, { prefix: prefix });

Expand All @@ -18,7 +19,7 @@ export async function CreateSigningClient(
const accountAddress = accounts[0].address;

// Create an signing client with created wallet
const signingClient = await SigningStargateClient.connectWithSigner(
const signingClient = await SigningCosmWasmClient.connectWithSigner(
endpoint,
wallet,
{
Expand All @@ -29,7 +30,7 @@ export async function CreateSigningClient(
}

export async function getHeight(
client: SigningStargateClient,
client: SigningCosmWasmClient,
chainId: string
) {
// To Check if the client is connected to local chain
Expand Down Expand Up @@ -107,7 +108,7 @@ export async function getContainerIdByPartialName(chainName: string): Promise<st
}

export async function getBalance(
client: SigningStargateClient,
client: SigningCosmWasmClient,
address: string
) {
const balance = await client.getBalance(address, "stake");
Expand Down

0 comments on commit ca09b36

Please sign in to comment.