-
Notifications
You must be signed in to change notification settings - Fork 51
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of github.com:Epistimio/orion into orion_service_2
- Loading branch information
Showing
110 changed files
with
5,013 additions
and
2,460 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
name: Playwright Tests | ||
|
||
on: | ||
push: | ||
branches: [ master, develop ] | ||
pull_request: | ||
branches: [ master, develop ] | ||
release: | ||
types: [published] | ||
workflow_dispatch: | ||
|
||
defaults: | ||
run: | ||
working-directory: dashboard/src | ||
|
||
jobs: | ||
test-dashboard-src-with-playwright: | ||
timeout-minutes: 60 | ||
runs-on: ubuntu-latest | ||
# Playwright requires Node.js 14 or higher. | ||
strategy: | ||
matrix: | ||
node-version: [14.x, 16.x] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
|
||
# Launch Orion backend | ||
|
||
- name: Launch Orion server | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.8 | ||
- name: Install Orion from local copy | ||
run: python -m pip install ../../.[profet] | ||
|
||
- name: Setup MongoDB | ||
uses: supercharge/[email protected] | ||
with: | ||
mongodb-version: 4.2 | ||
mongodb-db: orion_dashboard_test | ||
- name: Populate MongoDB | ||
run: | | ||
cd ../../ | ||
python .github/workflows/orion/pickle_to_mongodb.py | ||
cd dashboard/src/ | ||
- name: Start Orion backend | ||
run: | | ||
# Start Orion backend in repository root folder. | ||
cd ../../ | ||
mkdir -p gunicorn_tmp_dir | ||
orion -vv serve -c .github/workflows/orion/orion_config_mongodb.yaml 2> orion-backend-${{ matrix.node-version }}.log & | ||
cd dashboard/src/ | ||
- name: Install dependencies | ||
run: yarn | ||
# check files formatting using Carbon's `ci-check` script | ||
- name: Check files formatting | ||
run: yarn ci-check | ||
- name: Install Playwright Browsers | ||
run: yarn playwright install --with-deps | ||
|
||
# Launch Orion frontend, needed by Playwright | ||
- name: Build dashboard | ||
run: yarn build | ||
- name: Serve build | ||
run: ./node_modules/.bin/serve -l 3000 build/ & | ||
|
||
- name: Run Playwright tests | ||
run: yarn playwright test --project=chromium --reporter=line |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,13 +38,8 @@ jobs: | |
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.8 | ||
- run: python -m pip install git+https://github.com/notoraptor/orion.git@feature/benchmark_webapi_rebased#egg=orion[profet] | ||
- name: info about current directory | ||
run: df . | ||
- name: check filesystem type using df | ||
run: df -Th | ||
- name: check filesystem type using fstab | ||
run: cat /etc/fstab | ||
- name: Install Orion from local copy | ||
run: python -m pip install ../../.[profet] | ||
|
||
- name: Setup MongoDB | ||
uses: supercharge/[email protected] | ||
|
@@ -69,7 +64,7 @@ jobs: | |
# check files formatting using Carbon's `ci-check` script | ||
- run: yarn ci-check | ||
# Run tests | ||
# NB: Tests are running in parallel by default, this may cause backend to receive too many requests in small time | ||
# NB: Tests are running in parallel by default, this may cause backend to receive too many requests in few time | ||
# Option --runInBand allows running tests sequentially: https://jestjs.io/docs/cli#--runinband | ||
- run: yarn test --all --verbose --runInBand | ||
# Upload orion backend log. | ||
|
Oops, something went wrong.