Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
AlejandroCabeza committed Jul 22, 2024
1 parent 1191eec commit 237654a
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 18 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/base_daily_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
workflow_call:
inputs:
nim:
description: 'Nim Branch'
description: 'Nim Configuration'
required: true
type: string # Following this format: [{"branch": ..., "memory_management": ...}, ...]
cpu:
Expand All @@ -18,7 +18,7 @@ on:
default: "[]"

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}-${{ github.job }}
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Base Tests
name: Continuous Integration

on:
push:
Expand All @@ -12,12 +12,6 @@ concurrency:
cancel-in-progress: true

jobs:
delete_cache:
name: Delete github action's branch cache
runs-on: ubuntu-latest
steps:
- uses: snnaplab/delete-branch-cache-action@v1

test:
needs: delete_cache
timeout-minutes: 90
Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ concurrency:

jobs:
codecov:
# Improvement: Split single job into run tests, generate coverage, and upload to codecov.
name: Run coverage and upload to codecov
runs-on: ubuntu-22.04
env:
Expand Down Expand Up @@ -43,13 +42,13 @@ jobs:
run: |
nimble install_pinned
- name: Install coverage tools and setup
- name: Setup coverage
run: |
sudo apt-get update
sudo apt-get install -y lcov build-essential git curl
mkdir coverage
- name: Run coverage-enabled test suite
- name: Run test suite with coverage flags
run: |
export NIMFLAGS="--lineDir:on --passC:-fprofile-arcs --passC:-ftest-coverage --passL:-fprofile-arcs --passL:-ftest-coverage"
nimble testnative
Expand Down
13 changes: 7 additions & 6 deletions .github/workflows/linter.yml → .github/workflows/linters.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,21 @@ jobs:
name: NPH
runs-on: ubuntu-latest
steps:
- name: Checkout
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 2 # In PR, has extra merge commit: ^1 = PR, ^2 = base

- name: Lint style
- name: Setup NPH
# Pin nph to a specific version to avoid sudden style differences.
# Updating nph version should be accompanied with running the new
# version on the fluffy directory.
# Updating nph version should be accompanied with running the new version on the fluffy directory.
run: |
VERSION="v0.5.1"
ARCHIVE="nph-linux_x64.tar.gz"
curl -L "https://github.com/arnetheduck/nph/releases/download/${VERSION}/${ARCHIVE}" -o ${ARCHIVE}
tar -xzf ${ARCHIVE}
- name: Check style
run: |
shopt -s extglob # Enable extended globbing
./nph examples libp2p tests tools *.@(nim|nims|nimble)
git diff --exit-code
./nph --check examples libp2p tests tools *.@(nim|nims|nimble)

0 comments on commit 237654a

Please sign in to comment.