Skip to content

Commit

Permalink
trial 3
Browse files Browse the repository at this point in the history
  • Loading branch information
Hans-Chrstian committed Aug 7, 2024
1 parent 4b111b0 commit 9314520
Showing 1 changed file with 5 additions and 10 deletions.
15 changes: 5 additions & 10 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,17 +34,15 @@ jobs:
CKAN_DATASTORE_READ_URL: postgresql://datastore_read:pass@postgres/datastore_test
CKAN_SOLR_URL: http://solr:8983/solr/ckan
CKAN_REDIS_URL: redis://redis:6379/1
APP_DIR: /srv/app/src
APP_DIR: /srv/app/src # Define APP_DIR here

steps:
- uses: actions/checkout@v4
- name: Install requirements
# Install any extra requirements your extension has here (dev requirements, other extensions etc)
run: |
pip install -r requirements.txt
pip install -r dev-requirements.txt
pip install --upgrade pytest-rerunfailures
pip install -e 'git+https://github.com/ckan/ckanext-scheming.git@release-3.0.0#egg=ckanext-scheming[requirements]'
pip install -e 'git+https://github.com/ckan/ckanext-harvest.git@v1.5.6#egg=ckanext-harvest[requirements]'
pip install -e 'git+https://github.com/ckan/ckanext-dcat.git@v1.5.1#egg=ckanext-dcat[requirements]'
- name: Clone and Install ckanext-scheming
Expand All @@ -55,25 +53,22 @@ jobs:
pip3 install -e .
- name: Develop setup
run: |
source venv/bin/activate
python3 setup.py develop
- name: Setup extension
# Extra initialization steps
run: |
# Replace default path to CKAN core config file with the one on the container
sed -i -e 's/use = config:.*/use = config:\/srv\/app\/src\/ckan\/test-core.ini/' test.ini
ckan -c test.ini db init
- name: Run tests
run: pytest --ckan-ini=test.ini --cov=ckanext.fairdatapoint --disable-warnings ckanext/fairdatapoint
run: |
pytest --ckan-ini=test.ini --cov=ckanext.fairdatapoint --disable-warnings ckanext/fairdatapoint
- name: Generate coverage report
run: coverage xml -o coverage.xml
run: |
coverage xml -o coverage.xml
- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@v2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

- uses: actions/checkout@v4
- name: REUSE Compliance Check
uses: fsfe/reuse-action@v4

0 comments on commit 9314520

Please sign in to comment.