Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

import blocks before test #3364

Open
wants to merge 13 commits into
base: master
Choose a base branch
from
4 changes: 4 additions & 0 deletions .github/workflows/build_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@ jobs:
with:
command: build
args: --all
- name: import blocks
run: |
ls -ls `pwd`/target
bash ./scripts/import_block.sh main ~/.starcoin/main
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里 import_block.sh 没有用。

- name: test
run: bash ./scripts/auto_rerun_test.sh
- name: move-prover-test
Expand Down
66 changes: 66 additions & 0 deletions .github/workflows/build_test_with_blocks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
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: 120
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: |
bash ./scripts/import_net_block.sh main ~/.starcoin/main
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

感觉应该拉个 release 版本的去测试,import 执行会很慢。

- name: test
run: bash ./scripts/auto_rerun_test.sh
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个测试就没必要跑了。

- name: move-prover-test
uses: actions-rs/cargo@v1
with:
command: test
args: -p starcoin-move-prover
- name: check changed files
run: bash ./scripts/changed_files.sh
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个测试也一样

- name: integration test dev environment
env:
RUST_LOG: info
RUST_BACKTRACE: full
STARCOIN_WS: ${{ secrets.STARCOIN_WS }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里要用 ci 跑起来的那个节点去测试。

uses: actions-rs/cargo@v1
with:
command: test
args: --test integration -- -e cmd