From aca6b7be8956e7ca76bec62a9dde7e4c7282b9f9 Mon Sep 17 00:00:00 2001 From: Carlos Alejandro Gutierrez Sandoval Date: Wed, 18 Oct 2023 15:52:40 -0600 Subject: [PATCH] WIP integration CI --- .github/workflows/pull-request.yml | 25 +++++++++++++++++++++++-- Makefile.toml | 14 ++++++++++++++ 2 files changed, 37 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index 9744b9b2..93ba39e3 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -120,14 +120,19 @@ jobs: filters: | devenv: - 'devenv/**' - + - uses: actions/upload-artifact@v3 + with: + name: docker-images + path: /tmp/images - name: Checkout if: steps.changes.outputs.devenv == 'true' uses: actions/checkout@v3 - name: Build devenv containers if: steps.changes.outputs.devenv == 'true' - run: ./devenv/build.sh + run: | + ./devenv/build.sh + docker save -o /tmp/images/bulk.tar $(docker images -q) vitest: runs-on: ubuntu-latest @@ -146,3 +151,19 @@ jobs: working-directory: ./romeo/asset-contract - run: npm run test working-directory: ./romeo/asset-contract + + integretion: + runs-on: ubuntu-latest + needs: ["linter", "devenv"] + steps: + - uses: actions/checkout@v3 + - uses: actions/download-artifact@v3 + with: + name: docker-images + path: /tmp/images + - uses: davidB/rust-cargo-make@v1 + with: + version: "0.36.13" + + - run: "docker load --input /tmp/images/bulk.tar" + #- run: "cargo make integration" diff --git a/Makefile.toml b/Makefile.toml index 44da538e..cfa50fc9 100644 --- a/Makefile.toml +++ b/Makefile.toml @@ -187,3 +187,17 @@ dependencies = ["clean", "format", "coverage", "release"] [tasks.default] run_task = "pr-validation" + +# Integration +# ---------- +#[tasks.build-devenv] +#command = "./build.sh" + +[tasks.build-testbed] +command = "pushd integration && ./bin/build && popd" + + +[tasks.integration] +#dependencies = ["build-devenv", "build-testbed"] +dependencies = ["build-testbed"] +command = "./integration/bin/test"