From 7993e3e6ec676fdd1e44bee8de6ddc1196683b11 Mon Sep 17 00:00:00 2001 From: Vitor Lima Date: Mon, 17 Jun 2024 16:16:33 -0300 Subject: [PATCH] chore: macos workflow test --- .github/workflows/build-macos-x64.yml | 17 +++++++++++++++-- .github/workflows/tests.yml | 8 ++++++-- 2 files changed, 21 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-macos-x64.yml b/.github/workflows/build-macos-x64.yml index dd2b31e..6fec89b 100644 --- a/.github/workflows/build-macos-x64.yml +++ b/.github/workflows/build-macos-x64.yml @@ -19,6 +19,16 @@ jobs: - name: Checkout code uses: actions/checkout@v4 + - name: Cache cargo + uses: actions/cache@v3 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} + restore-keys: | + ${{ runner.os }}-cargo- + - name: Install Rust toolchain and components uses: actions-rs/toolchain@v1 with: @@ -28,8 +38,11 @@ jobs: run: touch .env # Build the modules - - name: Build - run: cargo build --verbose --release + - name: Release build + uses: actions-rs/cargo@v1 + with: + command: build + args: --release --all-features --verbose # Run tests - name: Run tests diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 81db9a5..189c4e9 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -36,8 +36,12 @@ jobs: - name: Create empty .env file run: touch .env - - name: Build - run: cargo build --verbose + # Build the modules + - name: Release build + uses: actions-rs/cargo@v1 + with: + command: build + args: --verbose - name: Test run: cargo test --verbose