diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 4014ea42..68100ff6 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -20,21 +20,9 @@ jobs: - name: Build env: IS_GITHUB_ACTION: true - run: | - mkdir res && cd astra && RUSTFLAGS='-C link-arg=-s' cargo build --target wasm32-unknown-unknown --release - cd .. && cp target/wasm32-unknown-unknown/release/astra.wasm res/ - - name: Build - env: - IS_GITHUB_ACTION: true - run: cargo build --workspace --target wasm32-unknown-unknown --release - - name: Wasm copy - run: cp target/wasm32-unknown-unknown/release/*.wasm res/ + run: sh build.sh - name: Run Cargo tests env: IS_GITHUB_ACTION: true run: cargo test --workspace -- --nocapture - # - name: Run Ava tests - # env: - # IS_GITHUB_ACTION: true - # run: cd astra && sh test.sh diff --git a/astra-factory/src/lib.rs b/astra-factory/src/lib.rs index 3eecda8b..87e8832b 100644 --- a/astra-factory/src/lib.rs +++ b/astra-factory/src/lib.rs @@ -17,7 +17,7 @@ const FACTORY_OWNER_KEY: &[u8; 5] = b"OWNER"; const CODE_METADATA_KEY: &[u8; 8] = b"METADATA"; // The values used when writing initial data to the storage. -const DAO_CONTRACT_INITIAL_CODE: &[u8] = include_bytes!("../../res/astra.wasm"); +const DAO_CONTRACT_INITIAL_CODE: &[u8] = include_bytes!("../../target/wasm32-unknown-unknown/release/astra.wasm"); const DAO_CONTRACT_INITIAL_VERSION: Version = [3, 0]; const DAO_CONTRACT_NO_DATA: &str = "no data";