From 7d7fc1fadb89ee09406e663364e9001c7a9e9f99 Mon Sep 17 00:00:00 2001 From: Nathan Seva Date: Mon, 15 Jul 2024 18:44:23 -0300 Subject: [PATCH] add CI --- .github/workflows/sc.yml | 25 +++++++++++++++++++ smart-contract/.github/workflows/ci-tests.yml | 18 ------------- 2 files changed, 25 insertions(+), 18 deletions(-) create mode 100644 .github/workflows/sc.yml delete mode 100644 smart-contract/.github/workflows/ci-tests.yml diff --git a/.github/workflows/sc.yml b/.github/workflows/sc.yml new file mode 100644 index 0000000..622c76d --- /dev/null +++ b/.github/workflows/sc.yml @@ -0,0 +1,25 @@ +name: Smart contract lint and tests +on: [push] +jobs: + unit-tests: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - uses: actions/setup-node@v4 + with: + node-version: '18' + cache: 'npm' + cache-dependency-path: smart-contract/package-lock.json + + - name: Install + run: npm ci + working-directory: smart-contract + + - name: Lint + run: npm run fmt:check + working-directory: smart-contract + + - name: Test + run: npm run test + working-directory: smart-contract diff --git a/smart-contract/.github/workflows/ci-tests.yml b/smart-contract/.github/workflows/ci-tests.yml deleted file mode 100644 index eddd4ba..0000000 --- a/smart-contract/.github/workflows/ci-tests.yml +++ /dev/null @@ -1,18 +0,0 @@ -name: massa sc ci tests -on: [push] -jobs: - unit-tests: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - - uses: actions/setup-node@v3 - with: - node-version: '18' - cache: 'npm' - - - name: Install - run: npm ci - - - name: Test - run: npm run test