2020-03-23 15:39:19 +01:00
|
|
|
name: Benchmark
|
|
|
|
|
2020-03-23 18:09:14 +01:00
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
2021-09-05 19:45:29 +02:00
|
|
|
- main
|
2022-04-25 20:11:11 +02:00
|
|
|
pull_request:
|
|
|
|
paths:
|
|
|
|
- ".github/workflows/benchmark.yml"
|
|
|
|
- "tests/benchmark.py"
|
2020-03-23 15:39:19 +01:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
2021-11-22 12:51:22 +01:00
|
|
|
python-version: ["3.10"]
|
|
|
|
os: [ubuntu-20.04]
|
2020-03-23 15:39:19 +01:00
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- name: Set up Python ${{ matrix.python-version }}
|
2022-03-01 10:48:23 +01:00
|
|
|
uses: actions/setup-python@v3
|
2020-03-23 15:39:19 +01:00
|
|
|
with:
|
|
|
|
python-version: ${{ matrix.python-version }}
|
2021-11-22 12:51:22 +01:00
|
|
|
cache: pip
|
|
|
|
cache-dependency-path: "setup.py"
|
2020-03-23 15:39:19 +01:00
|
|
|
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
|
|
|
python -m pip install --upgrade pip
|
2020-03-23 18:08:06 +01:00
|
|
|
python -m pip install --upgrade nujson orjson simplejson
|
|
|
|
python -m pip install .
|
2020-03-23 15:39:19 +01:00
|
|
|
|
|
|
|
- name: Tests
|
|
|
|
shell: bash
|
|
|
|
run: |
|
|
|
|
python tests/benchmark.py
|