Update validator config, canonical->human addr
This commit is contained in:
parent
616dc71456
commit
2662e3e2c9
@ -359,9 +359,9 @@ describe("CosmWasmClient", () => {
|
||||
const raw = await client.queryContractRaw(contract.address, configKey);
|
||||
assert(raw, "must get result");
|
||||
expect(JSON.parse(fromAscii(raw))).toEqual({
|
||||
verifier: toBase64(Bech32.decode(contract.initMsg.verifier).data),
|
||||
beneficiary: toBase64(Bech32.decode(contract.initMsg.beneficiary).data),
|
||||
funder: toBase64(Bech32.decode(alice.address0).data),
|
||||
verifier: contract.initMsg.verifier,
|
||||
beneficiary: contract.initMsg.beneficiary,
|
||||
funder: alice.address0,
|
||||
});
|
||||
});
|
||||
|
||||
@ -420,7 +420,7 @@ describe("CosmWasmClient", () => {
|
||||
|
||||
const client = await CosmWasmClient.connect(wasmd.endpoint);
|
||||
await expectAsync(client.queryContractSmart(contract.address, { broken: {} })).toBeRejectedWithError(
|
||||
/Error parsing into type hackatom::contract::QueryMsg: unknown variant/i,
|
||||
/Error parsing into type hackatom::msg::QueryMsg: unknown variant/i,
|
||||
);
|
||||
});
|
||||
|
||||
|
||||
@ -295,8 +295,8 @@ describe("WasmExtension", () => {
|
||||
const data = models[0];
|
||||
expect(data.key).toEqual(hackatomConfigKey);
|
||||
const value = JSON.parse(fromAscii(data.value));
|
||||
expect(value.verifier).toMatch(base64Matcher);
|
||||
expect(value.beneficiary).toMatch(base64Matcher);
|
||||
expect(value.verifier).toMatch(bech32AddressMatcher);
|
||||
expect(value.beneficiary).toMatch(bech32AddressMatcher);
|
||||
});
|
||||
|
||||
it("rejects for non-existent address", async () => {
|
||||
@ -317,8 +317,8 @@ describe("WasmExtension", () => {
|
||||
const raw = await client.wasm.queryContractRaw(hackatomContractAddress, hackatomConfigKey);
|
||||
assert(raw.data, "must get result");
|
||||
const model = JSON.parse(fromAscii(raw.data));
|
||||
expect(model.verifier).toMatch(base64Matcher);
|
||||
expect(model.beneficiary).toMatch(base64Matcher);
|
||||
expect(model.verifier).toMatch(bech32AddressMatcher);
|
||||
expect(model.beneficiary).toMatch(bech32AddressMatcher);
|
||||
});
|
||||
|
||||
it("returns empty for missing key", async () => {
|
||||
@ -356,7 +356,7 @@ describe("WasmExtension", () => {
|
||||
const request = { nosuchkey: {} };
|
||||
await expectAsync(
|
||||
client.wasm.queryContractSmart(hackatomContractAddress, request),
|
||||
).toBeRejectedWithError(/Error parsing into type hackatom::contract::QueryMsg: unknown variant/i);
|
||||
).toBeRejectedWithError(/Error parsing into type hackatom::msg::QueryMsg: unknown variant/i);
|
||||
});
|
||||
|
||||
it("throws for non-existent address", async () => {
|
||||
|
||||
@ -90,21 +90,21 @@ export const validator = {
|
||||
* `jq ".app_state.genutil.gen_txs[0].auth_info.signer_infos[0].public_key" scripts/wasmd/template/.wasmd/config/genesis.json`
|
||||
*/
|
||||
pubkey: {
|
||||
type: "tendermint/PubKeySecp256k1",
|
||||
value: "AoSRL8/aA1oDkHPd0IMtLpozhGdgFafzMCKmmOQ0olJn",
|
||||
type: "/cosmos.crypto.secp256k1.PubKey",
|
||||
key: "AjOB0SSyyLVBcOe0GK0TuLmXlCVWY/h8cnhKvwbnbdII",
|
||||
},
|
||||
/**
|
||||
* delegator_address from /cosmos.staking.v1beta1.MsgCreateValidator in scripts/wasmd/template/.wasmd/config/genesis.json
|
||||
*
|
||||
* `jq ".app_state.genutil.gen_txs[0].body.messages[0].delegator_address" scripts/wasmd/template/.wasmd/config/genesis.json`
|
||||
*/
|
||||
delegatorAddress: "wasm1jq32x9gj3n5lj2cgrcksypk3zegxnxgy8vzymc",
|
||||
delegatorAddress: "wasm1tjgue6r5kqj5dets24pwaa9u7wuzucpwuva0rv",
|
||||
/**
|
||||
* validator_address from /cosmos.staking.v1beta1.MsgCreateValidator in scripts/wasmd/template/.wasmd/config/genesis.json
|
||||
*
|
||||
* `jq ".app_state.genutil.gen_txs[0].body.messages[0].validator_address" scripts/wasmd/template/.wasmd/config/genesis.json`
|
||||
*/
|
||||
validatorAddress: "wasmvaloper1jq32x9gj3n5lj2cgrcksypk3zegxnxgyjshc4z",
|
||||
validatorAddress: "wasmvaloper1tjgue6r5kqj5dets24pwaa9u7wuzucpwfsgndk",
|
||||
accountNumber: 0,
|
||||
sequence: 1,
|
||||
};
|
||||
@ -114,7 +114,7 @@ export const deployedHackatom = {
|
||||
codeId: 1,
|
||||
source: "https://crates.io/api/v1/crates/hackatom/not-yet-released/download",
|
||||
builder: "cosmwasm/rust-optimizer:0.10.8",
|
||||
checksum: "08537c4f191980bc835f08ecb9077bb60df1097c1c0793312e0f21cbfca868d2",
|
||||
checksum: "3da31e1978e492d041a60905319f454f21b381beac274d07081aee390d0a63d7",
|
||||
instances: [
|
||||
{
|
||||
beneficiary: alice.address0,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user