Skip to content

Commit 894fcf8

Browse files
rearrange graph tests
1 parent afc17bd commit 894fcf8

23 files changed

+92
-91
lines changed

Diff for: .drone.star

+7-25
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,10 @@ config = {
9797
],
9898
"skip": False,
9999
},
100-
"settings": {
100+
"settingsAndNotification": {
101101
"suites": [
102102
"apiSettings",
103+
"apiNotification",
103104
],
104105
"skip": False,
105106
"withRemotePhp": [True],
@@ -117,17 +118,18 @@ config = {
117118
"NOTIFICATIONS_DEBUG_ADDR": "0.0.0.0:9174",
118119
},
119120
},
120-
"graph": {
121+
"graphBasicAndGroup": {
121122
"suites": [
122-
"apiGraph",
123123
"apiServiceAvailability",
124+
"apiGraph",
125+
"apiGraphGroup",
124126
],
125127
"skip": False,
126128
"withRemotePhp": [True],
127129
},
128-
"graphUserGroup": {
130+
"graphUser": {
129131
"suites": [
130-
"apiGraphUserGroup",
132+
"apiGraphUser",
131133
],
132134
"skip": False,
133135
"withRemotePhp": [True],
@@ -194,26 +196,6 @@ config = {
194196
],
195197
"accounts_hash_difficulty": "default",
196198
},
197-
"notification": {
198-
"suites": [
199-
"apiNotification",
200-
],
201-
"skip": False,
202-
"withRemotePhp": [True],
203-
"emailNeeded": True,
204-
"extraEnvironment": {
205-
"EMAIL_HOST": EMAIL_SMTP_HOST,
206-
"EMAIL_PORT": EMAIL_PORT,
207-
},
208-
"extraServerEnvironment": {
209-
"OCIS_ADD_RUN_SERVICES": "notifications",
210-
"NOTIFICATIONS_SMTP_HOST": EMAIL_SMTP_HOST,
211-
"NOTIFICATIONS_SMTP_PORT": EMAIL_SMTP_PORT,
212-
"NOTIFICATIONS_SMTP_INSECURE": "true",
213-
"NOTIFICATIONS_SMTP_SENDER": EMAIL_SMTP_SENDER,
214-
"NOTIFICATIONS_DEBUG_ADDR": "0.0.0.0:9174",
215-
},
216-
},
217199
"antivirus": {
218200
"suites": [
219201
"apiAntivirus",

Diff for: docs/ocis/development/testing.md

+9-9
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ While running the tests, oCIS server is started with [ociswrapper](https://githu
6262

6363
```bash
6464
WITH_WRAPPER=false \
65-
BEHAT_FEATURE='tests/acceptance/features/apiGraphUserGroup/createUser.feature:26' \
65+
BEHAT_FEATURE='tests/acceptance/features/apiGraphUser/createUser.feature:26' \
6666
make -C tests/acceptance/docker test-ocis-feature-ocis-storage
6767
```
6868

@@ -119,7 +119,7 @@ The tests for a single feature (a feature file) can also be run against the diff
119119
For example;
120120

121121
```bash
122-
BEHAT_FEATURE='tests/acceptance/features/apiGraphUserGroup/createUser.feature' \
122+
BEHAT_FEATURE='tests/acceptance/features/apiGraphUser/createUser.feature' \
123123
make -C tests/acceptance/docker test-ocis-feature-ocis-storage
124124
```
125125

@@ -130,23 +130,23 @@ make -C tests/acceptance/docker test-ocis-feature-ocis-storage
130130
And to run a single scenario in a feature, you can do:
131131

132132
{{< hint info >}}
133-
A specific scenario from a feature can be run by adding `:<line-number>` at the end of the feature file path. For example, to run the scenario at line 26 of the feature file `apiGraphUserGroup/createUser.feature`, simply add the line number like this: `apiGraphUserGroup/createUser.feature:26`. Note that the line numbers mentioned in the examples might not always point to a scenario, so always check the line numbers before running the test.
133+
A specific scenario from a feature can be run by adding `:<line-number>` at the end of the feature file path. For example, to run the scenario at line 26 of the feature file `apiGraphUser/createUser.feature`, simply add the line number like this: `apiGraphUser/createUser.feature:26`. Note that the line numbers mentioned in the examples might not always point to a scenario, so always check the line numbers before running the test.
134134
{{< /hint >}}
135135

136136
```bash
137-
BEHAT_FEATURE='tests/acceptance/features/apiGraphUserGroup/createUser.feature:26' \
137+
BEHAT_FEATURE='tests/acceptance/features/apiGraphUser/createUser.feature:26' \
138138
make -C tests/acceptance/docker test-ocis-feature-ocis-storage
139139
```
140140

141141
Similarly, with S3 storage;
142142

143143
```bash
144144
# run a whole feature
145-
BEHAT_FEATURE='tests/acceptance/features/apiGraphUserGroup/createUser.feature' \
145+
BEHAT_FEATURE='tests/acceptance/features/apiGraphUser/createUser.feature' \
146146
make -C tests/acceptance/docker test-ocis-feature-s3ng-storage
147147

148148
# run a single scenario
149-
BEHAT_FEATURE='tests/acceptance/features/apiGraphUserGroup/createUser.feature:26' \
149+
BEHAT_FEATURE='tests/acceptance/features/apiGraphUser/createUser.feature:26' \
150150
make -C tests/acceptance/docker test-ocis-feature-s3ng-storage
151151
```
152152

@@ -227,16 +227,16 @@ Useful environment variables:
227227
`BEHAT_FEATURE`: to run a single feature
228228

229229
{{< hint info >}}
230-
A specific scenario from a feature can be run by adding `:<line-number>` at the end of the feature file path. For example, to run the scenario at line 26 of the feature file `apiGraphUserGroup/createUser.feature`, simply add the line number like this: `apiGraphUserGroup/createUser.feature:26`. Note that the line numbers mentioned in the examples might not always point to a scenario, so always check the line numbers before running the test.
230+
A specific scenario from a feature can be run by adding `:<line-number>` at the end of the feature file path. For example, to run the scenario at line 26 of the feature file `apiGraphUser/createUser.feature`, simply add the line number like this: `apiGraphUser/createUser.feature:26`. Note that the line numbers mentioned in the examples might not always point to a scenario, so always check the line numbers before running the test.
231231
{{< /hint >}}
232232

233233
> Example:
234234
>
235-
> BEHAT_FEATURE=tests/acceptance/features/apiGraphUserGroup/createUser.feature
235+
> BEHAT_FEATURE=tests/acceptance/features/apiGraphUser/createUser.feature
236236
>
237237
> Or
238238
>
239-
> BEHAT_FEATURE=tests/acceptance/features/apiGraphUserGroup/createUser.feature:13
239+
> BEHAT_FEATURE=tests/acceptance/features/apiGraphUser/createUser.feature:13
240240
241241
`BEHAT_SUITE`: to run a single suite
242242

Diff for: tests/acceptance/config/behat.yml

+21-2
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,28 @@ default:
124124
- TrashbinContext:
125125
- SharingNgContext:
126126

127-
apiGraphUserGroup:
127+
apiGraphUser:
128128
paths:
129-
- "%paths.base%/../features/apiGraphUserGroup"
129+
- "%paths.base%/../features/apiGraphUser"
130+
context: *common_ldap_suite_context
131+
contexts:
132+
- FeatureContext: *common_feature_context_params
133+
- SettingsContext:
134+
- GraphContext:
135+
- SpacesContext:
136+
- CapabilitiesContext:
137+
- FilesVersionsContext:
138+
- OCSContext:
139+
- PublicWebDavContext:
140+
- TUSContext:
141+
- SpacesTUSContext:
142+
- OcisConfigContext:
143+
- TrashbinContext:
144+
- SharingNgContext:
145+
146+
apiGraphGroup:
147+
paths:
148+
- "%paths.base%/../features/apiGraphGroup"
130149
context: *common_ldap_suite_context
131150
contexts:
132151
- FeatureContext: *common_feature_context_params

0 commit comments

Comments
 (0)