Skip to content

Commit 84c460a

Browse files
committed
[DATALAD RUNCMD] Add crippled-filesystems CI run from the extension-template
=== Do not change lines below === { "chain": [], "cmd": "sed -e \"s,helloworld,container,g\" < ../datalad-extension-template/.github/workflows/test_crippledfs.yml > .github/workflows/test_crippledfs.yml", "exit": 0, "extra_inputs": [], "inputs": [], "outputs": [], "pwd": "." } ^^^ Do not change lines above ^^^
1 parent ed733e3 commit 84c460a

File tree

1 file changed

+55
-0
lines changed

1 file changed

+55
-0
lines changed
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: crippled-filesystems
2+
3+
on: [pull_request]
4+
5+
jobs:
6+
test:
7+
8+
runs-on: ubuntu-latest
9+
10+
steps:
11+
- name: Set up system
12+
shell: bash
13+
run: |
14+
bash <(wget -q -O- http://neuro.debian.net/_files/neurodebian-travis.sh)
15+
# enable repo for devel git-annex, if needed
16+
#sudo sed -e 's|\(deb.*data\)|#\1|' -e 's|/debian |/debian-devel |' /etc/apt/sources.list.d/neurodebian.sources.list | sudo tee /etc/apt/sources.list.d/neurodebian-devel.sources.list
17+
sudo apt-get update -qq
18+
sudo apt-get install eatmydata
19+
sudo eatmydata apt-get install git-annex-standalone dosfstools
20+
# 500 MB VFAT FS in a box
21+
sudo dd if=/dev/zero of=/crippledfs.img count=500 bs=1M
22+
sudo mkfs.vfat /crippledfs.img
23+
# mount
24+
sudo mkdir /crippledfs
25+
sudo mount -o "uid=$(id -u),gid=$(id -g)" /crippledfs.img /crippledfs
26+
- name: Set up environment
27+
run: |
28+
git config --global user.email "[email protected]"
29+
git config --global user.name "GitHub Almighty"
30+
- uses: actions/checkout@v4
31+
- name: Set up Python 3.9
32+
uses: actions/setup-python@v5
33+
with:
34+
python-version: 3.9
35+
- name: Install dependencies
36+
run: |
37+
pip install -r requirements-devel.txt
38+
python -m pip install --upgrade pip
39+
- name: Installation
40+
run: |
41+
# package install
42+
python -m pip install .
43+
- name: Run tests
44+
env:
45+
# forces all test repos/paths into the VFAT FS
46+
TMPDIR: /crippledfs
47+
run: |
48+
mkdir -p __testhome__
49+
cd __testhome__
50+
# give detailed info on actual test setup
51+
datalad wtf
52+
echo "== mount >>"
53+
mount
54+
echo "<< mount =="
55+
python -m pytest -s -v --doctest-modules --cov=datalad_container --pyargs datalad_container

0 commit comments

Comments
 (0)