apirunner 0.5.0 → 0.5.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,299 +0,0 @@
1
- ---
2
- - name: "There should return recommendations / ratings for a discovery request for genre:67"
3
- request:
4
- headers:
5
- Content-Type: 'application/json'
6
- path: '/users/duffyduck/predictions/discovery/genre:67'
7
- method: 'GET'
8
- response_expectation:
9
- status_code: 200
10
- body: /^\[({"m\d+":[0-5]\.[05]},)+{"m\d+":[0-5]\.[05]}\]$/
11
- - name: "There should return exatctly 5 recommendations / ratings for a discovery request for genre:67 with per_page 5"
12
- request:
13
- headers:
14
- Content-Type: 'application/json'
15
- path: '/users/duffyduck/predictions/discovery/genre:67'
16
- parameters:
17
- per_page: 5
18
- page: 1
19
- method: 'GET'
20
- response_expectation:
21
- status_code: 200
22
- body: /^\[({"m\d+":[0-5]\.[05]},){4}{"m\d+":[0-5]\.[05]}\]$/
23
- - name: "There should not return any recommendations / ratings on a dicovery request for genre:67 for a non existing user"
24
- request:
25
- headers:
26
- Content-Type: 'application/json'
27
- path: '/users/daisyduck/predictions/discovery/genre:67'
28
- method: 'GET'
29
- response_expectation:
30
- status_code: 404
31
- body:
32
- - name: "There should return recommendations / ratings for a discovery request for plot_keyword:2"
33
- request:
34
- headers:
35
- Content-Type: 'application/json'
36
- path: '/users/duffyduck/predictions/discovery/plot_keyword:2'
37
- method: 'GET'
38
- response_expectation:
39
- status_code: 200
40
- body: /^\[({"m\d+":[0-5]\.[05]},)+{"m\d+":[0-5]\.[05]}\]$/
41
- - name: "There should return exactly 5 recommendations / ratings for a discovery request for plot_keyword:2 with per_page 5"
42
- request:
43
- headers:
44
- Content-Type: 'application/json'
45
- path: '/users/duffyduck/predictions/discovery/plot_keyword:2'
46
- parameters:
47
- per_page: 5
48
- page: 1
49
- method: 'GET'
50
- response_expectation:
51
- status_code: 200
52
- body: /^\[({"m\d+":[0-5]\.[05]},){4}{"m\d+":[0-5]\.[05]}\]$/
53
- - name: "There should not return any recommendations / ratings on a dicovery request for plot_keyword:2 for a non existing user"
54
- request:
55
- headers:
56
- Content-Type: 'application/json'
57
- path: '/users/daisyduck/predictions/discovery/plot_keyword:2'
58
- method: 'GET'
59
- response_expectation:
60
- status_code: 404
61
- body:
62
- - name: "There should return recommendations / ratings for a discovery request for place_keyword:2"
63
- request:
64
- headers:
65
- Content-Type: 'application/json'
66
- path: '/users/duffyduck/predictions/discovery/place_keyword:2'
67
- method: 'GET'
68
- response_expectation:
69
- status_code: 200
70
- body: /^\[({"m\d+":[0-5]\.[05]},)+{"m\d+":[0-5]\.[05]}\]$/
71
- - name: "There should return exactly 5 recommendations / ratings for a discovery request for place_keyword:2 with per_page 5"
72
- request:
73
- headers:
74
- Content-Type: 'application/json'
75
- path: '/users/duffyduck/predictions/discovery/place_keyword:2'
76
- parameters:
77
- per_page: 5
78
- page: 1
79
- method: 'GET'
80
- response_expectation:
81
- status_code: 200
82
- body: /^\[({"m\d+":[0-5]\.[05]},){4}{"m\d+":[0-5]\.[05]}\]$/
83
- - name: "There should not return any recommendations / ratings on a dicovery request for place_keyword:200 for a non existing user"
84
- request:
85
- headers:
86
- Content-Type: 'application/json'
87
- path: '/users/daisyduck/predictions/discovery/place_keyword:200'
88
- method: 'GET'
89
- response_expectation:
90
- status_code: 404
91
- body:
92
- - name: "There should return recommendations / ratings for a discovery request for time_keyword:198"
93
- request:
94
- headers:
95
- Content-Type: 'application/json'
96
- path: '/users/duffyduck/predictions/discovery/time_keyword:198'
97
- method: 'GET'
98
- response_expectation:
99
- status_code: 200
100
- body: /^\[({"m\d+":[0-5]\.[05]},)+{"m\d+":[0-5]\.[05]}\]$/
101
- - name: "There should return exactly 5 recommendations / ratings for a discovery request for time_keyword:2 with per_page 5"
102
- request:
103
- headers:
104
- Content-Type: 'application/json'
105
- path: '/users/duffyduck/predictions/discovery/time_keyword:2'
106
- parameters:
107
- per_page: 5
108
- page: 1
109
- method: 'GET'
110
- response_expectation:
111
- status_code: 200
112
- body: /^\[({"m\d+":[0-5]\.[05]},){4}{"m\d+":[0-5]\.[05]}\]$/
113
- - name: "There should not return any recommendations / ratings on a dicovery request for time_keyword:198 for a non existing user"
114
- request:
115
- headers:
116
- Content-Type: 'application/json'
117
- path: '/users/daisyduck/predictions/discovery/place_keyword:198'
118
- method: 'GET'
119
- response_expectation:
120
- status_code: 404
121
- body:
122
- - name: "There should return recommendations / ratings for a discovery request for emotion_keyword:7"
123
- request:
124
- headers:
125
- Content-Type: 'application/json'
126
- path: '/users/duffyduck/predictions/discovery/emotion_keyword:7'
127
- method: 'GET'
128
- response_expectation:
129
- status_code: 200
130
- body: /^\[({"m\d+":[0-5]\.[05]},)+{"m\d+":[0-5]\.[05]}\]$/
131
- - name: "There should return exactly 5 recommendations / ratings for a discovery request for emotion_keyword:7 with per_page 5"
132
- request:
133
- headers:
134
- Content-Type: 'application/json'
135
- path: '/users/duffyduck/predictions/discovery/emotion_keyword:7'
136
- parameters:
137
- per_page: 5
138
- page: 1
139
- method: 'GET'
140
- response_expectation:
141
- status_code: 200
142
- body: /^\[({"m\d+":[0-5]\.[05]},){4}{"m\d+":[0-5]\.[05]}\]$/
143
- - name: "There should not return any recommendations / ratings on a dicovery request for emotion_keyword:7 for a non existing user"
144
- request:
145
- headers:
146
- Content-Type: 'application/json'
147
- path: '/users/daisyduck/predictions/discovery/emotion_keyword:7'
148
- method: 'GET'
149
- response_expectation:
150
- status_code: 404
151
- body:
152
- - name: "There should return recommendations / ratings for a discovery request for intended_audience:13"
153
- request:
154
- headers:
155
- Content-Type: 'application/json'
156
- path: '/users/duffyduck/predictions/discovery/intended_audience:13'
157
- method: 'GET'
158
- response_expectation:
159
- status_code: 200
160
- body: /^\[({"m\d+":[0-5]\.[05]},)+{"m\d+":[0-5]\.[05]}\]$/
161
- - name: "There should return exactly 5 recommendations / ratings for a discovery request for intended_audience:13 with per_page 5"
162
- request:
163
- headers:
164
- Content-Type: 'application/json'
165
- path: '/users/duffyduck/predictions/discovery/intended_audience:13'
166
- parameters:
167
- per_page: 5
168
- page: 1
169
- method: 'GET'
170
- response_expectation:
171
- status_code: 200
172
- body: /^\[({"m\d+":[0-5]\.[05]},){4}{"m\d+":[0-5]\.[05]}\]$/
173
- - name: "There should not return any recommendations / ratings on a dicovery request for intended_audience:13 for a non existing user"
174
- request:
175
- headers:
176
- Content-Type: 'application/json'
177
- path: '/users/daisyduck/predictions/discovery/intended_audience:13'
178
- method: 'GET'
179
- response_expectation:
180
- status_code: 404
181
- body:
182
- - name: "Personal discovery with per_page set to 20 should return 20 results"
183
- request:
184
- headers:
185
- Content-Type: 'application/json'
186
- path: '/users/duffyduck/predictions/discovery/genre:1'
187
- method: 'GET'
188
- parameters:
189
- per_page: 20
190
- response_expectation:
191
- status_code: 200
192
- body: /^\[({"m\d+":[0-5]\.[05]},){19}{"m\d+":[0-5]\.[05]}\]$/
193
- - name: "Personal discovery with per_page set to 20 and page set to 2 should return 20 results too"
194
- request:
195
- headers:
196
- Content-Type: 'application/json'
197
- path: '/users/duffyduck/predictions/discovery/genre:1'
198
- method: 'GET'
199
- parameters:
200
- per_page: 20
201
- page: 2
202
- response_expectation:
203
- status_code: 200
204
- body: /^\[({"m\d+":[0-5]\.[05]},){19}{"m\d+":[0-5]\.[05]}\]$/
205
- - name: "Personal discovery without per_page set return more than 20 results"
206
- request:
207
- headers:
208
- Content-Type: 'application/json'
209
- path: '/users/duffyduck/predictions/discovery/genre:1'
210
- method: 'GET'
211
- response_expectation:
212
- status_code: 200
213
- body: /^\[({"m\d+":[0-5]\.[05]},){20,1600}{"m\d+":[0-5]\.[05]}\]$/
214
- - name: "Unpersonalized discovery should return a lot of movies for a certain genre"
215
- request:
216
- headers:
217
- Content-Type: 'application/json'
218
- path: '/discovery/genre:1'
219
- method: 'GET'
220
- response_expectation:
221
- status_code: 200
222
- body: /^\[("m\d+",){20,1600}"m\d+"\]$/
223
- - name: "Unpersonalized discovery with per_page set to 20 should return 20 movies for a certain genre"
224
- request:
225
- headers:
226
- Content-Type: 'application/json'
227
- path: '/discovery/genre:1'
228
- method: 'GET'
229
- parameters:
230
- per_page: 20
231
- response_expectation:
232
- status_code: 200
233
- body: /^\[("m\d+",){19}"m\d+"\]$/
234
- - name: "Unpersonalized discovery with per_page set to 20 and page set to 2 should return 20 movies for a certain genre too"
235
- request:
236
- headers:
237
- Content-Type: 'application/json'
238
- path: '/discovery/genre:1'
239
- method: 'GET'
240
- parameters:
241
- per_page: 20
242
- page: 2
243
- response_expectation:
244
- status_code: 200
245
- body: /^\[("m\d+",){19}"m\d+"\]$/
246
- - name: "Unpersonalized discovery should return between 1 and 2000 movies for a certain emotion_keyword"
247
- request:
248
- headers:
249
- Content-Type: 'application/json'
250
- path: '/discovery/emotion_keyword:7'
251
- method: 'GET'
252
- response_expectation:
253
- status_code: 200
254
- body: /^\[("m\d+",){1,2000}"m\d+"\]$/
255
- - name: "Unpersonalized discovery should return between 1 and 2000 movies for a certain intended_audience"
256
- request:
257
- headers:
258
- Content-Type: 'application/json'
259
- path: '/discovery/intended_audience:13'
260
- method: 'GET'
261
- response_expectation:
262
- status_code: 200
263
- body: /^\[("m\d+",){1,2000}"m\d+"\]$/
264
- - name: "Unpersonalized discovery should return between 1 and 2000 movies for a certain place_keyword"
265
- request:
266
- headers:
267
- Content-Type: 'application/json'
268
- path: '/discovery/place_keyword:2'
269
- method: 'GET'
270
- response_expectation:
271
- status_code: 200
272
- body: /^\[("m\d+",){1,2000}"m\d+"\]$/
273
- - name: "Unpersonalized discovery should return between 1 and 2000 movies for a certain time_keyword"
274
- request:
275
- headers:
276
- Content-Type: 'application/json'
277
- path: '/discovery/time_keyword:198'
278
- method: 'GET'
279
- response_expectation:
280
- status_code: 200
281
- body: /^\[("m\d+",){1,2000}"m\d+"\]$/
282
- - name: "Unpersonalized discovery should return between 1 and 2000 movies for a certain plot_keyword"
283
- request:
284
- headers:
285
- Content-Type: 'application/json'
286
- path: '/discovery/plot_keyword:2'
287
- method: 'GET'
288
- response_expectation:
289
- status_code: 200
290
- body: /^\[("m\d+",){1,2000}"m\d+"\]$/
291
- - name: "Unpersonalized discovery should return between 1 and 2000 movies for a certain genre"
292
- request:
293
- headers:
294
- Content-Type: 'application/json'
295
- path: '/discovery/genre:67'
296
- method: 'GET'
297
- response_expectation:
298
- status_code: 200
299
- body: /^\[("m\d+",){1,2000}"m\d+"\]$/
@@ -1,168 +0,0 @@
1
- ---
2
- - name: 'Create new adult user duffydad'
3
- request:
4
- headers:
5
- Content-Type: 'application/json'
6
- path: '/users/duffydad'
7
- method: 'PUT'
8
- body:
9
- username: 'duffydad'
10
- watchlist:
11
- - m1035
12
- - m2087
13
- blacklist:
14
- - m1554
15
- - m2981
16
- skiplist:
17
- - m1590
18
- - m1056
19
- ratings:
20
- m12493: 4.0
21
- m1875: 2.5
22
- m7258: 3.0
23
- m7339: 4.0
24
- m3642: 5.0
25
- expires_at: 2011-09-09T22:41:50+00:00
26
- response_expectation:
27
- status_code: 201
28
- headers:
29
- Last-Modified: /.*/
30
- body:
31
- username: 'duffydad'
32
- watchlist:
33
- - m1035
34
- - m2087
35
- blacklist:
36
- - m1554
37
- - m2981
38
- skiplist:
39
- - m1590
40
- - m1056
41
- ratings:
42
- m12493: 4.0
43
- m1875: 2.5
44
- m7258: 3.0
45
- m7339: 4.0
46
- m3642: 5.0
47
- fsk: "18"
48
- - name: 'Expect the number of movies of genre horror for adult duffydad to be between 33 and 200'
49
- wait_before_request: 5
50
- request:
51
- headers:
52
- Content-Type: 'application/json'
53
- path: '/users/duffydad/predictions/discovery/genre:43'
54
- method: 'GET'
55
- response_expectation:
56
- status_code: 200
57
- body: /^\[(\{"m\d+":[0-5]\.[05]\},){33,199}\{"m\d+":[0-5]\.[05]\}\]$/
58
- - name: 'Create new non-adult user duffykid with ratings'
59
- request:
60
- headers:
61
- Content-Type: 'application/json'
62
- path: '/users/duffykid'
63
- method: 'PUT'
64
- body:
65
- username: 'duffykid'
66
- fsk: "0"
67
- ratings:
68
- m12493: 4.0
69
- m1875: 2.5
70
- m7258: 3.0
71
- m7339: 4.0
72
- m3642: 5.0
73
- expires_at: 2011-09-09T22:41:50+00:00
74
- response_expectation:
75
- status_code: 201
76
- headers:
77
- Last-Modified: /.*/
78
- body:
79
- username: 'duffykid'
80
- ratings:
81
- m12493: 4.0
82
- m1875: 2.5
83
- m7258: 3.0
84
- m7339: 4.0
85
- m3642: 5.0
86
- fsk: "0"
87
- - name: 'Expect the number of movies of genre horror for non-adult duffykid to be between 0 and 33'
88
- wait_before_request: 5
89
- request:
90
- headers:
91
- Content-Type: 'application/json'
92
- path: '/users/duffykid/predictions/discovery/genre:43'
93
- method: 'GET'
94
- response_expectation:
95
- status_code: 200
96
- body: /^\[(\{"m\d+":[0-5]\.[05]\},){0,33}\{"m\d+":[0-5]\.[05]\}\]$/
97
- - name: 'Create new FSK Check User'
98
- request:
99
- headers:
100
- Content-Type: 'application/json'
101
- path: '/users/teletubby'
102
- method: 'PUT'
103
- body:
104
- username: 'teletubby'
105
- fsk: 12
106
- expires_at: 2011-09-09T22:41:50+00:00
107
- response_expectation:
108
- status_code: 201
109
- headers:
110
- Last-Modified: /.*/
111
- body:
112
- username: 'teletubby'
113
- fsk: 12
114
- - name: "We put one rating in expectation that fsk 12 does not change"
115
- request:
116
- headers:
117
- Content-Type: 'application/json'
118
- path: '/users/teletubby/ratings'
119
- method: 'PUT'
120
- body:
121
- m765: 1.0
122
- response_expectation:
123
- status_code: 204
124
- body:
125
- - name: 'Check users fsk after rating - should be still 12'
126
- request:
127
- headers:
128
- Content-Type: 'application/json'
129
- path: '/users/teletubby'
130
- method: 'GET'
131
- response_expectation:
132
- status_code: 200
133
- headers:
134
- Last-Modified: /.*/
135
- body:
136
- username: 'teletubby'
137
- fsk: "12"
138
- - name: "We put another rating in expectation that fsk 12 does not change"
139
- request:
140
- headers:
141
- Content-Type: 'application/json'
142
- path: '/users/teletubby/ratings'
143
- method: 'PUT'
144
- body:
145
- m42: 1.0
146
- response_expectation:
147
- status_code: 204
148
- body:
149
- - name: 'Check users fsk after rating - should be still 12'
150
- request:
151
- headers:
152
- Content-Type: 'application/json'
153
- path: '/users/teletubby'
154
- method: 'GET'
155
- response_expectation:
156
- status_code: 200
157
- headers:
158
- Last-Modified: /.*/
159
- body:
160
- username: 'teletubby'
161
- fsk: "12"
162
- - name: 'Delete fsk testuser'
163
- request:
164
- path: '/users/teletubby'
165
- method: 'DELETE'
166
- body: {}
167
- response_expectation:
168
- status_code: 202