Skip to content

Commit

Permalink
Remove submitMediaLibrary() helper
Browse files Browse the repository at this point in the history
  • Loading branch information
ol0lll committed Sep 3, 2024
1 parent 0d5f88e commit 0fddc49
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 11 deletions.
3 changes: 2 additions & 1 deletion tests/src/FunctionalJavascript/MediaGalleryModifyTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,8 @@ public function testAddRemove(): void {
$media = $this->getMediaByName('reference.jpg');
$this->toggleMedia([$media->id()]);

$this->submitMediaLibrary();
$this->clickCssSelector('.media-library-widget-modal .form-actions button.button--primary');
$this->assertWaitOnAjaxRequest();

$this->clickSave();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,6 @@ public function openMediaLibrary(string $fieldName): void {
$this->clickCssSelector($button_selector);
}

/**
* Submit changes in media library modal.
*/
public function submitMediaLibrary(): void {
$this->clickCssSelector('.media-library-widget-modal .form-actions button');

$this->assertWaitOnAjaxRequest();
}

/**
* Upload file inside media library.
*
Expand Down
3 changes: 2 additions & 1 deletion tests/src/FunctionalJavascript/ThunderMediaTestTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ public function selectMedia(string $fieldName, array $medias): void {

$this->toggleMedia($medias);

$this->submitMediaLibrary();
$this->clickCssSelector('.media-library-widget-modal .form-actions button.button--primary');
$this->assertWaitOnAjaxRequest();
}

/**
Expand Down

0 comments on commit 0fddc49

Please sign in to comment.