TYPO3 CMS  TYPO3_6-2
ActionTest.php
Go to the documentation of this file.
1 <?php
3 
17 require_once dirname(dirname(__FILE__)) . '/AbstractActionTestCase.php';
18 
23 
27  protected $assertionDataSetDirectory = 'typo3/sysext/workspaces/Tests/Functional/DataHandling/IRRE/CSV/Modify/DataSet/';
28 
37  public function createParentContent() {
38  parent::createParentContent();
39  $this->assertAssertionDataSet('createParentContent');
40 
41  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
42  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
43  ->setTable(self::TABLE_Content)->setField('header')->setValues('Testing #1'));
44  }
45 
50  public function modifyParentContent() {
51  parent::modifyParentContent();
52  $this->assertAssertionDataSet('modifyParentContent');
53 
54  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
55  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
56  ->setTable(self::TABLE_Content)->setField('header')->setValues('Testing #1'));
57  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
58  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdLast)->setRecordField(self::FIELD_ContentHotel)
59  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1'));
60  }
61 
66  public function deleteParentContent() {
67  parent::deleteParentContent();
68  $this->assertAssertionDataSet('deleteParentContent');
69 
70  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
71  $this->assertThat($responseSections, $this->getRequestSectionDoesNotHaveRecordConstraint()
72  ->setTable(self::TABLE_Content)->setField('header')->setValues('Regular Element #2'));
73  }
74 
80  parent::deleteParentContentAndDiscardDeletedParent();
81  $this->assertAssertionDataSet('deleteParentContentNDiscardDeletedParent');
82 
83  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
84  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
85  ->setTable(self::TABLE_Content)->setField('header')->setValues('Regular Element #2'));
86  }
87 
92  public function copyParentContent() {
93  parent::copyParentContent();
94  $this->assertAssertionDataSet('copyParentContent');
95 
96  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
97  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
98  ->setRecordIdentifier(self::TABLE_Content . ':' . $this->recordIds['newContentId'])->setRecordField(self::FIELD_ContentHotel)
99  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1'));
100  }
101 
107  parent::copyParentContentToDifferentPage();
108  $this->assertAssertionDataSet('copyParentContentToDifferentPage');
109 
110  $responseSections = $this->getFrontendResponse(self::VALUE_PageIdTarget, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
111  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
112  ->setRecordIdentifier(self::TABLE_Content . ':' . $this->recordIds['newContentId'])->setRecordField(self::FIELD_ContentHotel)
113  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1'));
114  }
115 
121  parent::localizeParentContentInKeepMode();
122  $this->assertAssertionDataSet('localizeParentContentKeep');
123 
124  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, self::VALUE_LanguageId, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
125  $this->assertThat($responseSections, $this->getRequestSectionStructureDoesNotHaveRecordConstraint()
126  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdLast)->setRecordField(self::FIELD_ContentHotel)
127  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('[Translate to Dansk:] Hotel #1'));
128  }
129 
135  parent::localizeParentContentWithAllChildrenInKeepMode();
136  $this->assertAssertionDataSet('localizeParentContentWAllChildrenKeep');
137 
138  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, self::VALUE_LanguageId, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
139  $this->assertThat($responseSections, $this->getRequestSectionStructureDoesNotHaveRecordConstraint()
140  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdLast)->setRecordField(self::FIELD_ContentHotel)
141  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('[Translate to Dansk:] Hotel #1'));
142  }
143 
149  parent::localizeParentContentInSelectMode();
150  $this->assertAssertionDataSet('localizeParentContentSelect');
151 
152  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, self::VALUE_LanguageId, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
153  $this->assertThat($responseSections, $this->getRequestSectionStructureDoesNotHaveRecordConstraint()
154  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdLast)->setRecordField(self::FIELD_ContentHotel)
155  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('[Translate to Dansk:] Hotel #1'));
156  }
157 
163  parent::localizeParentContentWithAllChildrenInSelectMode();
164  $this->assertAssertionDataSet('localizeParentContentWAllChildrenSelect');
165 
166  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, self::VALUE_LanguageId, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
167  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
168  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdLast)->setRecordField(self::FIELD_ContentHotel)
169  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('[Translate to Dansk:] Hotel #1'));
170  }
171 
176  public function changeParentContentSorting() {
177  parent::changeParentContentSorting();
178  $this->assertAssertionDataSet('changeParentContentSorting');
179 
180  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
181  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
182  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdFirst)->setRecordField(self::FIELD_ContentHotel)
183  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1', 'Hotel #2'));
184  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
185  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdLast)->setRecordField(self::FIELD_ContentHotel)
186  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1'));
187  }
188 
194  parent::moveParentContentToDifferentPage();
195  $this->assertAssertionDataSet('moveParentContentToDifferentPage');
196 
197  $responseSections = $this->getFrontendResponse(self::VALUE_PageIdTarget, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
198  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
199  ->setTable(self::TABLE_Content)->setField('header')->setValues('Regular Element #2'));
200  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
201  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdLast)->setRecordField(self::FIELD_ContentHotel)
202  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1'));
203  }
204 
210  parent::moveParentContentToDifferentPageAndChangeSorting();
211  $this->assertAssertionDataSet('moveParentContentToDifferentPageNChangeSorting');
212 
213  $responseSections = $this->getFrontendResponse(self::VALUE_PageIdTarget, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
214  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
215  ->setTable(self::TABLE_Content)->setField('header')->setValues('Regular Element #2', 'Regular Element #1'));
216  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
217  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdFirst)->setRecordField(self::FIELD_ContentHotel)
218  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1', 'Hotel #2'));
219  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
220  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdLast)->setRecordField(self::FIELD_ContentHotel)
221  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1'));
222  }
223 
232  public function modifyPage() {
233  parent::modifyPage();
234  $this->assertAssertionDataSet('modifyPage');
235 
236  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
237  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
238  ->setTable(self::TABLE_Page)->setField('title')->setValues('Testing #1'));
239  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
240  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdFirst)->setRecordField(self::FIELD_ContentHotel)
241  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1', 'Hotel #2'));
242  }
243 
248  public function deletePage() {
249  parent::deletePage();
250  $this->assertAssertionDataSet('deletePage');
251 
252  $response = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId, FALSE);
253  $this->assertContains('RuntimeException', $response->getError());
254  }
255 
260  public function copyPage() {
261  parent::copyPage();
262  $this->assertAssertionDataSet('copyPage');
263 
264  $responseSections = $this->getFrontendResponse($this->recordIds['newPageId'], 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
265  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
266  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1', 'Hotel #2', 'Hotel #1'));
267  }
268 
274  parent::copyPageWithHotelBeforeParentContent();
275  $this->assertAssertionDataSet('copyPageWHotelBeforeParentContent');
276 
277  $responseSections = $this->getFrontendResponse($this->recordIds['newPageId'], 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
278  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
279  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1', 'Hotel #2', 'Hotel #1'));
280  }
281 
291  parent::createParentContentWithHotelAndOfferChildren();
292  $this->assertAssertionDataSet('createParentContentNHotelNOfferChildren');
293 
294  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
295  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
296  ->setTable(self::TABLE_Content)->setField('header')->setValues('Testing #1'));
297  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
298  ->setRecordIdentifier(self::TABLE_Content . ':' . $this->recordIds['newContentId'])->setRecordField(self::FIELD_ContentHotel)
299  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1'));
300  }
301 
307  parent::createAndCopyParentContentWithHotelAndOfferChildren();
308  $this->assertAssertionDataSet('createNCopyParentContentNHotelNOfferChildren');
309 
310  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
311  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
312  ->setTable(self::TABLE_Content)->setField('header')->setValues('Testing #1 (copy 1)'));
313  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
314  ->setRecordIdentifier(self::TABLE_Content . ':' . $this->recordIds['newContentId'])->setRecordField(self::FIELD_ContentHotel)
315  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1'));
316  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
317  ->setRecordIdentifier(self::TABLE_Content . ':' . $this->recordIds['copiedContentId'])->setRecordField(self::FIELD_ContentHotel)
318  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1'));
319  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
320  ->setRecordIdentifier(self::TABLE_Hotel . ':' . $this->recordIds['copiedHotelId'])->setRecordField(self::FIELD_HotelOffer)
321  ->setTable(self::TABLE_Offer)->setField('title')->setValues('Offer #1'));
322  }
323 
329  parent::createAndCopyParentContentWithHotelAndOfferChildrenAndDiscardCopiedParent();
330  $this->assertAssertionDataSet('createNCopyParentContentNHotelNOfferChildrenNDiscardCopiedParent');
331 
332  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
333  $this->assertThat($responseSections, $this->getRequestSectionDoesNotHaveRecordConstraint()
334  ->setTable(self::TABLE_Content)->setField('header')->setValues('Testing #1 (copy 1)'));
335  }
336 
342  parent::createAndLocalizeParentContentWithHotelAndOfferChildren();
343  $this->assertAssertionDataSet('createNLocalizeParentContentNHotelNOfferChildren');
344 
345  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, self::VALUE_LanguageId, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
346  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
347  ->setTable(self::TABLE_Content)->setField('header')->setValues('[Translate to Dansk:] Testing #1'));
348  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
349  ->setRecordIdentifier(self::TABLE_Content . ':' . $this->recordIds['newContentId'])->setRecordField(self::FIELD_ContentHotel)
350  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('[Translate to Dansk:] Hotel #1'));
351  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
352  ->setRecordIdentifier(self::TABLE_Hotel . ':' . $this->recordIds['localizedHotelId'])->setRecordField(self::FIELD_HotelOffer)
353  ->setTable(self::TABLE_Offer)->setField('title')->setValues('[Translate to Dansk:] Offer #1'));
354  }
355 
361  parent::createAndLocalizeParentContentWithHotelAndOfferChildrenAndDiscardCreatedParent();
362  $this->assertAssertionDataSet('createNLocalizeParentContentNHotelNOfferChildrenNDiscardCreatedParent');
363 
364  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, self::VALUE_LanguageId, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
365  $this->assertThat($responseSections, $this->getRequestSectionDoesNotHaveRecordConstraint()
366  ->setTable(self::TABLE_Content)->setField('header')->setValues('Testing #1', '[Translate to Dansk:] Testing #1'));
367  }
368 
374  parent::createAndLocalizeParentContentWithHotelAndOfferChildrenAndDiscardLocalizedParent();
375  $this->assertAssertionDataSet('createNLocalizeParentContentNHotelNOfferChildrenNDiscardLocalizedParent');
376 
377  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, self::VALUE_LanguageId, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
378  $this->assertThat($responseSections, $this->getRequestSectionDoesNotHaveRecordConstraint()
379  ->setTable(self::TABLE_Content)->setField('header')->setValues('[Translate to Dansk:] Testing #1'));
380  }
381 
386  public function modifyOnlyHotelChild() {
387  parent::modifyOnlyHotelChild();
388  $this->assertAssertionDataSet('modifyOnlyHotelChild');
389 
390  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
391  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
392  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdFirst)->setRecordField(self::FIELD_ContentHotel)
393  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1', 'Testing #1'));
394  }
395 
401  parent::modifyParentAndChangeHotelChildrenSorting();
402  $this->assertAssertionDataSet('modifyParentNChangeHotelChildrenSorting');
403 
404  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
405  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
406  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdFirst)->setRecordField(self::FIELD_ContentHotel)
407  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #2', 'Hotel #1'));
408  }
409 
414  public function modifyParentWithHotelChild() {
415  parent::modifyParentWithHotelChild();
416  $this->assertAssertionDataSet('modifyParentNHotelChild');
417 
418  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
419  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
420  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdFirst)->setRecordField(self::FIELD_ContentHotel)
421  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1', 'Testing #1'));
422  }
423 
429  parent::modifyParentWithHotelChildAndDiscardModifiedParent();
430  $this->assertAssertionDataSet('modifyParentNHotelChildNDiscardModifiedParent');
431 
432  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
433  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
434  ->setTable(self::TABLE_Content)->setField('header')->setValues('Regular Element #1'));
435  // Discarding the parent shall not discard the child records
436  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
437  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdFirst)->setRecordField(self::FIELD_ContentHotel)
438  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1', 'Testing #1'));
439  $this->assertThat($responseSections, $this->getRequestSectionStructureDoesNotHaveRecordConstraint()
440  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdFirst)->setRecordField(self::FIELD_ContentHotel)
441  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #2'));
442  }
443 
449  parent::modifyParentWithHotelChildAndDiscardAll();
450  $this->assertAssertionDataSet('modifyParentNHotelChildNDiscardAll');
451 
452  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
453  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
454  ->setTable(self::TABLE_Content)->setField('header')->setValues('Regular Element #1'));
455  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
456  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdFirst)->setRecordField(self::FIELD_ContentHotel)
457  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1', 'Hotel #2'));
458  }
459 
464  public function modifyParentAndAddHotelChild() {
465  parent::modifyParentAndAddHotelChild();
466  $this->assertAssertionDataSet('modifyParentNAddHotelChild');
467 
468  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
469  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
470  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdLast)->setRecordField(self::FIELD_ContentHotel)
471  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1', 'Hotel #2'));
472  }
473 
479  parent::modifyParentAndDeleteHotelChild();
480  $this->assertAssertionDataSet('modifyParentNDeleteHotelChild');
481 
482  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
483  $this->assertThat($responseSections, $this->getRequestSectionStructureHasRecordConstraint()
484  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdLast)->setRecordField(self::FIELD_ContentHotel)
485  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #1'));
486  $this->assertThat($responseSections, $this->getRequestSectionStructureDoesNotHaveRecordConstraint()
487  ->setRecordIdentifier(self::TABLE_Content . ':' . self::VALUE_ContentIdLast)->setRecordField(self::FIELD_ContentHotel)
488  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Hotel #2'));
489  }
490 
496  parent::modifyAndDiscardAndModifyParentWithHotelChild();
497  $this->assertAssertionDataSet('modifyNDiscardNModifyParentWHotelChild');
498 
499  $responseSections = $this->getFrontendResponse(self::VALUE_PageId, 0, self::VALUE_BackendUserId, self::VALUE_WorkspaceId)->getResponseSections();
500  $this->assertThat($responseSections, $this->getRequestSectionDoesNotHaveRecordConstraint()
501  ->setTable(self::TABLE_Content)->setField('header')->setValues('Testing #1'));
502  $this->assertThat($responseSections, $this->getRequestSectionDoesNotHaveRecordConstraint()
503  ->setTable(self::TABLE_Hotel)->setField('header')->setValues('Testing #1'));
504  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
505  ->setTable(self::TABLE_Content)->setField('header')->setValues('Testing #2'));
506  $this->assertThat($responseSections, $this->getRequestSectionHasRecordConstraint()
507  ->setTable(self::TABLE_Hotel)->setField('title')->setValues('Testing #2'));
508  }
509 
510 }
getFrontendResponse($pageId, $languageId=0, $backendUserId=0, $workspaceId=0, $failOnFailure=TRUE)