diff --git a/.github/workflows/build_test.yml b/.github/workflows/build_test.yml index 86347b70e0..aad0604644 100644 --- a/.github/workflows/build_test.yml +++ b/.github/workflows/build_test.yml @@ -8,7 +8,7 @@ jobs: build-and-test: name: build and test runs-on: self-hosted - timeout-minutes: 120 + timeout-minutes: 370 steps: - name: checkout uses: actions/checkout@v1 @@ -42,6 +42,13 @@ jobs: with: command: build args: --all + - name: import blocks + run: | + cp ./target/debug/starcoin_db_exporter . + cp ./target/debug/starcoin . + bash ./scripts/import_block.sh proxima /home/runner/.starcoin/proxima + - name: run proxima node + run: nohup ./starcoin -n proxima & - name: test run: bash ./scripts/auto_rerun_test.sh - name: move-prover-test diff --git a/.github/workflows/build_test_with_blocks.yml b/.github/workflows/build_test_with_blocks.yml new file mode 100644 index 0000000000..266bd64d79 --- /dev/null +++ b/.github/workflows/build_test_with_blocks.yml @@ -0,0 +1,64 @@ +name: Build and Test With Blocks +on: + workflow_dispatch: + # pull_request: + # branches: + # - master + +jobs: + build-and-test: + name: build and test + runs-on: self-hosted + timeout-minutes: 300 + steps: + - name: checkout + uses: actions/checkout@v1 + with: + submodules: recursive + - name: setup rust toolchain + uses: actions-rs/toolchain@v1 + with: + profile: minimal + components: rustfmt,clippy + - name: run fmt check + uses: actions-rs/cargo@v1 + with: + command: fmt + args: -- --check + - name: setup environment + run: bash ./scripts/dev_setup.sh -b -t -y + - name: run cargo clean + uses: actions-rs/cargo@v1 + with: + command: clean + - name: run cargo check + uses: actions-rs/cargo@v1 + env: + RUSTFLAGS: -D warnings + with: + command: clippy + args: --all-targets + - name: build + uses: actions-rs/cargo@v1 + with: + command: build + args: --all + - name: import blocks + run: | + cp ./target/debug/starcoin_db_exporter . + cp ./target/debug/starcoin . + bash ./scripts/import_block.sh proxima /home/runner/.starcoin/proxima + - name: move-prover-test + uses: actions-rs/cargo@v1 + with: + command: test + args: -p starcoin-move-prover + - name: integration test dev environment + env: + RUST_LOG: info + RUST_BACKTRACE: full + STARCOIN_WS: ${{ secrets.STARCOIN_WS }} + uses: actions-rs/cargo@v1 + with: + command: test + args: --test integration -- -e cmd