Skip to content

Commit 70ea5d2

Browse files
author
Tamara Gunkel
committed
fix behat test for series import
1 parent afd91df commit 70ea5d2

File tree

3 files changed

+51
-2
lines changed

3 files changed

+51
-2
lines changed

tests/behat/behat_block_opencast.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,8 @@ public function i_upload_a_testvideo() {
7272
$mapping->set('ocinstanceid', 1);
7373
$mapping->create();
7474

75-
$newdata = ['api_events.json', 'api_events_acl.json', 'api_events_detailpage.json', 'api_series.json',
75+
$newdata = ['api_events.json', 'api_events_secondvideo.json', 'api_events_acl.json',
76+
'api_events_detailpage.json', 'api_series.json',
7677
'api_series_metadata.json', 'api_series_two.json', 'api_events_with_publication.json',
7778
'api_series_filter.json', 'api_events_metadata.json', 'api_events_single_event.json',
7879
'api_events_nolimit.json', 'api_events_only_basic_infos.json'];
@@ -84,7 +85,8 @@ public function i_upload_a_testvideo() {
8485
}
8586

8687
// Add post request.
87-
$files = ['api_series_createseries.json', 'api_workflows_updatemetadata.json', 'api_workflows_startworkflow.json'];
88+
$files = ['api_series_createseries.json', 'api_workflows_updatemetadata.json', 'api_workflows_startworkflow.json',
89+
'api_workflows_updatemetadata_import.json'];
8890
$apitestable = new api_testable();
8991
foreach ($files as $file) {
9092
$apicall = file_get_contents(__DIR__ . "/../fixtures/api_calls/post/" . $file);
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
{
2+
"resource": "/api/events/bbbb-bbbb-bbbb-bbbb?withpublications=false&withacl=false",
3+
"response": {
4+
"identifier": "bbbb-bbbb-bbbb-bbbb",
5+
"creator": "",
6+
"presenter": [],
7+
"created": "2021-08-11T09:32:00Z",
8+
"is_part_of": "1111-1111-1111-1111-1111",
9+
"subjects": [],
10+
"start": "2021-08-11T09:32:00Z",
11+
"description": "",
12+
"language": "",
13+
"source": "",
14+
"title": "My video",
15+
"processing_state": "SUCCEEDED",
16+
"duration": 0,
17+
"license": "",
18+
"archive_version": 4,
19+
"contributor": [],
20+
"series": "Another series",
21+
"has_previews": false,
22+
"location": "",
23+
"rightsholder": "",
24+
"publication_status": [
25+
"engage-player",
26+
"api",
27+
"annotation"
28+
],
29+
"status": "EVENTS.EVENTS.STATUS.PROCESSED"
30+
}
31+
}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"resource": "/api/workflows_workflow_definition_identifier,event_identifier",
3+
"params": {
4+
"workflow_definition_identifier": "republish-metadata",
5+
"event_identifier": "bbbb-bbbb-bbbb-bbbb"
6+
},
7+
"response": {
8+
"workflow_definition_identifier": "republish-metadata",
9+
"identifier": 314922120,
10+
"creator": "",
11+
"description": "",
12+
"state": "instantiated",
13+
"title": "Veröffentliche Metadaten und ACLs auf Opencast Media Module (engage Channel)",
14+
"event_identifier": "bbbb-bbbb-bbbb-bbbb"
15+
}
16+
}

0 commit comments

Comments
 (0)