-
Notifications
You must be signed in to change notification settings - Fork 2
190 lines (180 loc) · 5.1 KB
/
test-action.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
name: Test Datalad Action
on:
pull_request: []
push:
branches:
- main
jobs:
install-datalad:
runs-on: ubuntu-latest
name: Install Datalad
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Datalad
uses: ./install
- name: Check Installed
run: which datalad
- name: Download Dataset Datalad Already Installed
uses: ./get
with:
source: https://github.com/psychoinformatics-de/studyforrest-data-phase2
dataset-get:
runs-on: ubuntu-latest
name: Install Datalad and Get
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Download Dataset
uses: ./get
with:
source: https://github.com/psychoinformatics-de/studyforrest-data-phase2
- name: Show Result
run: find .
- name: Test Result
run: |
[ -e studyforrest-data-phase2 ]
dataset-get-into-path:
runs-on: ubuntu-latest
name: Install Datalad and Get into specific path and get some sample data paths
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Download Dataset
uses: ./get
with:
source: https://github.com/psychoinformatics-de/studyforrest-data-phase2
dataset_path: dataset
paths: |
sub-22/sub-22_task-movie_beh.json
sub-23/sub-23_task-movie_beh.json
- name: Show Result
run: tree .
- name: Test Result
run: |
[ -e dataset ]
[ -e dataset/sub-22/sub-22_task-movie_beh.json ]
[ -e dataset/sub-23/sub-23_task-movie_beh.json ]
- name: Show Result
run: find .
dataset-get-globstar:
runs-on: ubuntu-latest
name: Install Datalad and Get test dataset with globs and tricky path names
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Download Dataset
uses: ./get
with:
source: https://github.com/datalad/datalad-action-test
globstar: true
paths: |
d1/**/*le.dat
d2/su b;1/**/* e.dat
- name: Show Result
run: |
tree .
find .
- name: Test Result
run: |
[ -e d1/sub1/sub2/file.dat ]
[ -e d1/sub1/file.dat ]
[ -e d1/file.dat ]
[ -e d2/su\ b\;1/su\ b\;2/f\ i\ l\ e.dat ]
[ -e d2/su\ b\;1/f\ i\ l\ e.dat ]
[ ! -e d2/f\ i\ l\ e.dat ]
working-directory: ./datalad-action-test
dataset-get-cache:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ ubuntu-20.04, macos-10.15, ubuntu-latest, macos-latest ]
name: Install Datalad, Get and Cache
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Download Dataset
uses: ./get
with:
source: https://github.com/psychoinformatics-de/studyforrest-data-phase2
- name: Show Result
run: find .
- name: Cache Dataset
uses: actions/cache@v3
with:
path: ./studyforrest-data-phase2
key: ${{ runner.os }}-studyforrest
dataset-get-custom-install:
runs-on: ubuntu-latest
name: Get With Install
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Download Dataset
uses: ./get
with:
branch: debian
source: https://github.com/psychoinformatics-de/studyforrest-data-phase2
- name: Show Result
run: find .
- name: Test Result
run: |
[ -e studyforrest-data-phase2 ]
install-datalad-branch:
runs-on: ubuntu-latest
name: Install Datalad via Branch
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Datalad
uses: ./install
with:
branch: debian
- name: Check Installed
run: which datalad
install-datalad-full-clone:
runs-on: ubuntu-latest
name: Install Datalad via Full Clone
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Datalad
uses: ./install
with:
full_clone: true
user: ${{ github.actor }}
email: ${{ github.actor }}@noreply.users.github.com
- name: Check Installed
run: which datalad
install-datalad-release:
runs-on: ubuntu-latest
name: Install Datalad via Release
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Datalad via Release
uses: ./install
with:
release: 0.18.0
- name: Check Installed
run: |
which datalad
datalad --version | grep 0.18.0
install-datalad-osf:
runs-on: ubuntu-latest
name: Install Datalad with some extensions
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Datalad and some extensions
uses: ./install
with:
pip_install:
- datalad-osf
- datalad-next
- name: Check Installed
run: |
which datalad
which git-remote-osf
datalad wtf -S extensions | grep datalad_next