Audit actions #27
Workflow file for this run
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: Web Performance | |
on: | |
workflow_dispatch: | |
push: | |
branches: [ main ] | |
paths: | |
- 'lib/wasm/**' | |
- 'lib/common/**' | |
- '.github/workflows/web-perf.yml' | |
pull_request: | |
branches: [ main, 'v[0-9]+.[0-9]+' ] | |
paths: | |
- 'lib/wasm/**' | |
- 'lib/common/**' | |
- '.github/workflows/web-perf.yml' | |
defaults: | |
run: | |
working-directory: binding/web | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: [3.8] | |
node-version: [lts/*] | |
include: | |
- python-version: 3.8 | |
indexPerformanceThresholdSec: 1.5 | |
searchPerformanceThresholdSec: 0.005 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Set up Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Install system dependencies | |
run: | | |
pip install packaging | |
pip install selenium | |
pip install webdriver-manager | |
- name: Pre-build dependencies | |
run: npm install yarn | |
- name: Install dependencies | |
run: yarn install | |
- name: Copy libs | |
run: yarn copywasm | |
- name: Build | |
run: yarn build | |
- name: Prepare Test | |
run: yarn setup-test | |
- name: Test | |
run: python test/perf_test.py --access_key ${{secrets.PV_VALID_ACCESS_KEY}} --audio_file ../../res/audio/multiple_keywords.wav | |
--index_performance_threshold_sec ${{ matrix.indexPerformanceThresholdSec }} --search_performance_threshold_sec ${{ matrix.searchPerformanceThresholdSec }} |