message: cosmwasm: Add CW1 contract details to testutils
diff: @@ -103,6 +103,14 @@ export const deployedCw3 = {
  ],
  };
  +/** Deployed as part of scripts/launchpad/init.sh */
  +export const deployedCw1 = {
  + codeId: 4,
  + source: "https://crates.io/api/v1/crates/cw1-subkeys/0.3.1/download",
  + builder: "cosmwasm/rust-optimizer:0.10.4",
  + instances: ["cosmos1vs2vuks65rq7xj78mwtvn7vvnm2gn7ad5me0d2"],
  +};
  +
  export const launchpad = {
  endpoint: "http://localhost:1317",
  chainId: "testing",
  @@ -141,6 +149,16 @@ export function pendingWithoutCw3(): void {
  }
  }
  +export function cw1Enabled(): boolean {
  + return !!process.env.CW1_ENABLED;
  +}
  +
  +export function pendingWithoutCw1(): void {
  + if (!cw1Enabled()) {
  + return pending("Set CW1_ENABLED to enable CW1-based tests");
  + }
  +}
  +
  /** Returns first element. Throws if array has a different length than 1. */
  export function fromOneElementArray<T>(elements: ArrayLike<T>): T {
  if (elements.length !== 1) throw new Error(`Expected exactly one element but got ${elements.length}`);
  