test-datalad_catalog-maint #685
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 is autogenerated from extensions.yaml using scripts/generate. | |
# See CONTRIBUTING.md for more information | |
name: test-datalad_catalog-maint | |
on: | |
# Trigger the workflow on pull request, | |
# but only if any given extension workflow was modified | |
pull_request: | |
paths: | |
- '.github/workflows/test-datalad_catalog-maint.yaml' | |
push: | |
branches: | |
- master | |
paths: | |
- '.github/workflows/test-datalad_catalog-maint.yaml' | |
# all should be triggered on cron | |
schedule: | |
- cron: '50 01 * * *' | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
# name mimics the one in .travis.yml for datalad build introduced in | |
# https://github.com/datalad/datalad/pull/4640 | |
annex-install-scenario: [neurodebian, datalad-git-annex-latest] | |
fail-fast: false | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up system | |
shell: bash | |
run: | | |
bash <(wget -q -O- http://neuro.debian.net/_files/neurodebian-travis.sh) | |
sudo apt-get update -qq | |
sudo apt-get install eatmydata python3-pip | |
sudo pip install datalad-installer | |
# just not to change the name from what we had already | |
case "${{ matrix.annex-install-scenario }}" in | |
neurodebian) | |
method=neurodebian;; | |
datalad-git-annex-latest) | |
method=datalad/git-annex;; | |
*) | |
echo "Unknown scenario ${{ matrix.annex-install-scenario }}" >&2 | |
exit 1 | |
esac | |
GITHUB_TOKEN=${{ secrets.datalad_github_token }} eatmydata \ | |
datalad-installer --sudo ok git-annex -m "${method}" | |
- name: Set up environment | |
run: | | |
git config --global user.email "[email protected]" | |
git config --global user.name "GitHub Almighty" | |
- name: Set up Python 3.8 | |
uses: actions/setup-python@v4 | |
with: | |
python-version: 3.8 | |
- name: Install DataLad (maint) | |
run: | | |
python -m pip install --upgrade pip | |
pip install https://github.com/datalad/datalad/archive/maint.zip | |
- name: Install datalad_catalog extension from PyPI ([devel,test,tests]) | |
run: | | |
pip install datalad-catalog[devel,test,tests] | |
- name: Install nose et al (just in case!) | |
# Note, that we need nose even in case of pytest, due to test helpers | |
# depending on it. | |
run: | | |
pip install pytest pytest-cov pytest-xdist nose vcrpy mock coverage | |
- name: WTF!? | |
run: | | |
datalad wtf | |
- name: datalad_catalog tests | |
run: | | |
mkdir -p __testhome__ | |
cd __testhome__ | |
python -m pytest -s -v --cov=datalad --cov=datalad_catalog --pyargs datalad_catalog |