fix new events #1115
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Testing 👨🔬 | |
on: | |
push: | |
branches: | |
- 'master' | |
- 'dev' | |
paths-ignore: | |
- 'docs/**' | |
- '.github/ISSUE_TEMPLATE/*' | |
- '*.md' | |
- '*.nimble' | |
- '.gitignore' | |
- 'LICENSE' | |
- '**/FUNDING.yml' | |
- '**/gh-pages.yml' | |
- '**/examples.yml' | |
- '**/language_bindings.yml' | |
- '**/examples/website/**' | |
pull_request: | |
paths-ignore: | |
- 'docs/**' | |
- '.github/ISSUE_TEMPLATE/*' | |
- '*.md' | |
- '*.nimble' | |
- '.gitignore' | |
- 'LICENSE' | |
- '**/FUNDING.yml' | |
- '**/gh-pages.yml' | |
- '**/examples.yml' | |
- '**/language_bindings.yml' | |
- '**/examples/website/**' | |
jobs: | |
dependencies: | |
name: Install dependencies 🧩 | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- ubuntu-latest | |
nim_version: | |
- '2.0.0' | |
- '2.0.6' | |
env: | |
TIMEOUT_EXIT_STATUS: 124 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/cache@v4 | |
with: | |
path: | | |
~/.nimble | |
.nim_runtime | |
key: ${{ runner.os }}-nimble-v2-${{ hashFiles('*.nimble') }} | |
- uses: jiro4989/setup-nim-action@v2 | |
with: | |
nim-version: ${{ matrix.nim_version }} | |
- name: Install Dependencies 🔃 | |
run: | | |
nimble refresh | |
nimble install -y -d | |
nimble install checksums -y | |
nimble install regex -y | |
# - uses: reviewdog/action-nimlint@v1 | |
# with: | |
# github_token: ${{ secrets.github_token }} | |
# reporter: github-pr-review # Change reporter. | |
# src: 'src/*.nim' | |
built_in_server: | |
name: Test C via built-in server 🧪 | |
needs: dependencies | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- ubuntu-latest | |
env: | |
TIMEOUT_EXIT_STATUS: 124 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/cache@v4 | |
with: | |
path: | | |
~/.nimble | |
.nim_runtime | |
key: ${{ runner.os }}-nimble-v2-${{ hashFiles('*.nimble') }} | |
- name: Build C tests (Default HTTP Server) ⚡ | |
run: | | |
export PATH=$PATH:$PWD/.nim_runtime/bin | |
cd tests | |
echo "###===--- Default for" $file "---===###" | |
for file in $(ls -v testc*.nim); do | |
echo "###===--- C Test for " $file " via built-in server ---===###" | |
nim c -d:debug --hints:off --warnings:off $file | |
done | |
shell: bash | |
async_http_server: | |
name: Test C via AsyncHttpServer 🧪 | |
needs: dependencies | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- ubuntu-latest | |
env: | |
TIMEOUT_EXIT_STATUS: 124 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/cache@v4 | |
with: | |
path: | | |
~/.nimble | |
.nim_runtime | |
key: ${{ runner.os }}-nimble-v2-${{ hashFiles('*.nimble') }} | |
- name: Build C tests (Default HTTP Server) ⚡ | |
run: | | |
export PATH=$PATH:$PWD/.nim_runtime/bin | |
cd tests | |
echo "###===--- Default for" $file "---===###" | |
for file in $(ls -v testc*.nim); do | |
echo "###===--- C Test for " $file " via stdlib ---===###" | |
nim c -d:debug -d:stdserver --hints:off --warnings:off $file | |
done | |
shell: bash | |
micro_async_http_server: | |
name: Test C via MicroAsyncHttpServer 🧪 | |
needs: dependencies | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- ubuntu-latest | |
env: | |
TIMEOUT_EXIT_STATUS: 124 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/cache@v4 | |
with: | |
path: | | |
~/.nimble | |
.nim_runtime | |
key: ${{ runner.os }}-nimble-v2-${{ hashFiles('*.nimble') }} | |
- name: Build C tests (MicroAsyncHttpServer) ⚡ | |
run: | | |
export PATH=$PATH:$PWD/.nim_runtime/bin | |
cd tests | |
for file in $(ls -v testc*.nim); do | |
echo "###===--- C Test for " $file " via MicroAsyncHttpServer ---===###" | |
nim c -d:micro -d:debug --hints:off --warnings:off $file | |
done | |
shell: bash | |
httpx: | |
name: Test C via HttpX 🧪 | |
needs: dependencies | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- ubuntu-latest | |
env: | |
TIMEOUT_EXIT_STATUS: 124 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/cache@v4 | |
with: | |
path: | | |
~/.nimble | |
.nim_runtime | |
key: ${{ runner.os }}-nimble-v2-${{ hashFiles('*.nimble') }} | |
- name: Build C tests (HttpX HTTP Server) ⚡ | |
run: | | |
export PATH=$PATH:$PWD/.nim_runtime/bin | |
cd tests | |
for file in $(ls -v testc*.nim); do | |
echo "###===--- C Test for " $file " via Httpx ---===###" | |
nim c -d:httpx -d:debug --hints:off --warnings:off $file | |
done | |
shell: bash | |
httpbeast: | |
name: Test C via HttpBeast 🧪 | |
needs: dependencies | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- ubuntu-latest | |
env: | |
TIMEOUT_EXIT_STATUS: 124 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/cache@v4 | |
with: | |
path: | | |
~/.nimble | |
.nim_runtime | |
key: ${{ runner.os }}-nimble-v2-${{ hashFiles('*.nimble') }} | |
- name: Build C tests (HttpBeast HTTP Server) ⚡ | |
run: | | |
export PATH=$PATH:$PWD/.nim_runtime/bin | |
cd tests | |
for file in $(ls -v testc*.nim); do | |
echo "###===--- C Test for " $file " via HttpBeast ---===###" | |
nim c -d:beast -d:debug --hints:off --warnings:off $file | |
done | |
shell: bash | |
js: | |
name: Test with JavaScript 🧪 | |
needs: dependencies | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- ubuntu-latest | |
env: | |
TIMEOUT_EXIT_STATUS: 124 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/cache@v4 | |
with: | |
path: | | |
~/.nimble | |
.nim_runtime | |
key: ${{ runner.os }}-nimble-v2-${{ hashFiles('*.nimble') }} | |
- name: Build JS tests 🍍 | |
run: | | |
export PATH=$PATH:$PWD/.nim_runtime/bin | |
cd tests | |
for file in $(ls -v testjs*.nim); do | |
echo "###===--- JS Test for " $file " ---===###" | |
nim js -d:debug --hints:off --warnings:off $file | |
done | |
shell: bash |