Skip to content

Commit

Permalink
Add access tests using shared-key for auth
Browse files Browse the repository at this point in the history
  • Loading branch information
roywilly committed Feb 9, 2024
1 parent 18f682b commit dd39fe1
Showing 1 changed file with 47 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/run_tests_access_drogon_manage_sharedkey.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Test access to Sumo with DROGON-MANAGE shared-key

on:
pull_request:
branches: [main]
schedule:
- cron: "48 4 * * *"
workflow_dispatch:

jobs:
build_pywheels:
name: PY ${{ matrix.python-version }} on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
python-version: ["3.11"]
os: [ubuntu-latest]
permissions:
contents: read
id-token: write

steps:
- uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}

- name: Install fmu-sumo
run: >
python -m pip install --upgrade pip &&
python -m pip install .[test]
- name: Run tests
shell: bash
run: |
pip list | grep -i sumo
environment: dev
key: ${{secrets.SHARED_KEY_DROGON_MANAGE_DEV}}
echo "$key" > ~/.sumo/88d2b022-3539-4dda-9e66-853801334a86.sharedkey
ls -l ~/.sumo/88d2b022-3539-4dda-9e66-853801334a86.sharedkey
cat ~/.sumo/88d2b022-3539-4dda-9e66-853801334a86.sharedkey
pytest -s --timeout=300 tests/test_access/tst_access_drogon_manage_login.py

0 comments on commit dd39fe1

Please sign in to comment.