Skip to content

Commit

Permalink
Test fail
Browse files Browse the repository at this point in the history
  • Loading branch information
ByteNacked committed Aug 28, 2024
1 parent 9f9061e commit 8ebce3d
Show file tree
Hide file tree
Showing 2 changed files with 131 additions and 126 deletions.
72 changes: 36 additions & 36 deletions .github/workflows/CI.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,39 +21,39 @@ jobs:
check:
uses: ./.github/workflows/check.yml

build:
uses: ./.github/workflows/build.yml
with:
macos: true
win-native: true
release: true
production: true

upload:
if: github.event_name == 'push' && github.ref_name == 'master'
runs-on: ubuntu-latest
needs: build
steps:
- name: Download artifacts
uses: actions/download-artifact@v4

- name: Delete previous release
uses: dev-drprasad/delete-tag-and-release@v1.1
with:
delete_release: true
tag_name: build
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Sleep
run: sleep 10

- name: Upload
uses: softprops/action-gh-release@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
prerelease: true
tag_name: build
draft: false
fail_on_unmatched_files: true
files: artifact/*
#build:
# uses: ./.github/workflows/build.yml
# with:
# macos: true
# win-native: true
# release: true
# production: true

#upload:
# if: github.event_name == 'push' && github.ref_name == 'master'
# runs-on: ubuntu-latest
# needs: build
# steps:
# - name: Download artifacts
# uses: actions/download-artifact@v4

# - name: Delete previous release
# uses: dev-drprasad/delete-tag-and-release@v1.1
# with:
# delete_release: true
# tag_name: build
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

# - name: Sleep
# run: sleep 10

# - name: Upload
# uses: softprops/action-gh-release@v2
# with:
# token: ${{ secrets.GITHUB_TOKEN }}
# prerelease: true
# tag_name: build
# draft: false
# fail_on_unmatched_files: true
# files: artifact/*
185 changes: 95 additions & 90 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,92 +10,92 @@ env:
BINARYEN_VERSION: version_111

jobs:
linux:
runs-on: [kuberunner, github-runner-01]
env:
RUSTUP_HOME: /tmp/rustup_home
steps:
- name: "ACTIONS: Checkout"
uses: actions/checkout@v4
with:
submodules: recursive

- name: "Install: Set cargo path"
run: echo "/tmp/cargo/bin" >> $GITHUB_PATH

- name: "Install: Rust toolchain"
uses: dsherret/rust-toolchain-file@v1

- name: "Install: Foundry"
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly

- name: "Install: Node.js"
uses: actions/setup-node@v4
with:
node-version: 20.x

- name: "Show: Versioning"
run: |
./scripts/gear.sh show
forge --version
- name: "Check: ethexe contracts"
run: |
cd ethexe/contracts
forge fmt --check
forge build --sizes
forge test -vvv
- name: "Check formatting: Gear"
run: ./scripts/gear.sh format gear --check

- name: "Check formatting: Doc"
run: ./scripts/gear.sh format doc --check

- name: "Check clippy: Gear"
run: ./scripts/gear.sh clippy gear --all-targets --all-features --locked

- name: "Check clippy: Examples"
run: ./scripts/gear.sh clippy examples --all-targets --locked

- name: "Test: Doc tests"
run: ./scripts/gear.sh test docs

- name: "Test: Changes in gsdk generated code"
run: |
GENERATED_CODE="gsdk/src/metadata/generated.rs"
./scripts/update-gsdk-metadata.sh
if [[ $(git diff --stat $GENERATED_CODE) != '' ]]; then
echo "Changes found in the gsdk generated code ($GENERATED_CODE). Please update it following the instructions in \`gsdk/HOW-TO-UPDATE.md\`."
git --no-pager diff $GENERATED_CODE
exit 1
fi
- name: "Test: Wasm-builder recommended toolchain matches rust-toolchain.toml"
run: |
TOOLCHAIN=$(grep 'channel' rust-toolchain.toml | cut -d '"' -f 2)
CARGO_TOOLCHAIN="utils/wasm-optimizer/src/cargo_toolchain.rs"
if ! grep -q "$TOOLCHAIN" $CARGO_TOOLCHAIN; then
echo "Please update PINNED_NIGHTLY_TOOLCHAIN constant in $CARGO_TOOLCHAIN to match rust-toolchain.toml."
exit 1
fi
- name: "Install: Rust stable toolchain"
uses: dtolnay/rust-toolchain@stable
with:
targets: wasm32-unknown-unknown
components: llvm-tools

- name: "Check: Compiling gstd on stable"
run: |
cargo +stable check -p gstd --target wasm32-unknown-unknown
cargo +stable check --manifest-path utils/wasm-builder/test-program/Cargo.toml
cargo +stable check --manifest-path utils/cargo-gbuild/test-program/Cargo.toml --workspace --target wasm32-unknown-unknown
- name: "Check: crates-io packages publishing"
run: cargo +stable run --release -p crates-io publish --simulate --registry-path /tmp/cargo-http-registry
#linux:
# runs-on: [kuberunner, github-runner-01]
# env:
# RUSTUP_HOME: /tmp/rustup_home
# steps:
# - name: "ACTIONS: Checkout"
# uses: actions/checkout@v4
# with:
# submodules: recursive

# - name: "Install: Set cargo path"
# run: echo "/tmp/cargo/bin" >> $GITHUB_PATH

# - name: "Install: Rust toolchain"
# uses: dsherret/rust-toolchain-file@v1

# - name: "Install: Foundry"
# uses: foundry-rs/foundry-toolchain@v1
# with:
# version: nightly

# - name: "Install: Node.js"
# uses: actions/setup-node@v4
# with:
# node-version: 20.x

# - name: "Show: Versioning"
# run: |
# ./scripts/gear.sh show
# forge --version

# - name: "Check: ethexe contracts"
# run: |
# cd ethexe/contracts
# forge fmt --check
# forge build --sizes
# forge test -vvv

# - name: "Check formatting: Gear"
# run: ./scripts/gear.sh format gear --check

# - name: "Check formatting: Doc"
# run: ./scripts/gear.sh format doc --check

# - name: "Check clippy: Gear"
# run: ./scripts/gear.sh clippy gear --all-targets --all-features --locked

# - name: "Check clippy: Examples"
# run: ./scripts/gear.sh clippy examples --all-targets --locked

# - name: "Test: Doc tests"
# run: ./scripts/gear.sh test docs

# - name: "Test: Changes in gsdk generated code"
# run: |
# GENERATED_CODE="gsdk/src/metadata/generated.rs"
# ./scripts/update-gsdk-metadata.sh
# if [[ $(git diff --stat $GENERATED_CODE) != '' ]]; then
# echo "Changes found in the gsdk generated code ($GENERATED_CODE). Please update it following the instructions in \`gsdk/HOW-TO-UPDATE.md\`."
# git --no-pager diff $GENERATED_CODE
# exit 1
# fi

# - name: "Test: Wasm-builder recommended toolchain matches rust-toolchain.toml"
# run: |
# TOOLCHAIN=$(grep 'channel' rust-toolchain.toml | cut -d '"' -f 2)
# CARGO_TOOLCHAIN="utils/wasm-optimizer/src/cargo_toolchain.rs"
# if ! grep -q "$TOOLCHAIN" $CARGO_TOOLCHAIN; then
# echo "Please update PINNED_NIGHTLY_TOOLCHAIN constant in $CARGO_TOOLCHAIN to match rust-toolchain.toml."
# exit 1
# fi

# - name: "Install: Rust stable toolchain"
# uses: dtolnay/rust-toolchain@stable
# with:
# targets: wasm32-unknown-unknown
# components: llvm-tools

# - name: "Check: Compiling gstd on stable"
# run: |
# cargo +stable check -p gstd --target wasm32-unknown-unknown
# cargo +stable check --manifest-path utils/wasm-builder/test-program/Cargo.toml
# cargo +stable check --manifest-path utils/cargo-gbuild/test-program/Cargo.toml --workspace --target wasm32-unknown-unknown

# - name: "Check: crates-io packages publishing"
# run: cargo +stable run --release -p crates-io publish --simulate --registry-path /tmp/cargo-http-registry

fuzzer:
runs-on: [kuberunner, github-runner-01]
Expand All @@ -111,6 +111,11 @@ jobs:
- name: "ACTIONS: Checkout"
uses: actions/checkout@v4

- name: "Install deps"
run: |
sudo apt update
sudo apt install -y xxd
- name: "MOUNT: Logs path"
run: |
FUZZER_LOGS_PATH=/mnt/fuzzer_logs
Expand All @@ -130,11 +135,11 @@ jobs:
- name: Install cargo-fuzz
run: cargo install cargo-fuzz

- name: "Run runtime-fuzzer crate tests"
run: ./scripts/gear.sh test fuzzer-tests
#- name: "Run runtime-fuzzer crate tests"
# run: ./scripts/gear.sh test fuzzer-tests

- name: "Check fuzzer competence with mutation test"
run: ./scripts/check-fuzzer.sh
#- name: "Check fuzzer competence with mutation test"
# run: ./scripts/check-fuzzer.sh

- name: "Check lazy pages fuzzer with smoke test"
run: ./scripts/check-lazy-pages-fuzzer.sh

0 comments on commit 8ebce3d

Please sign in to comment.