mirror of
https://github.com/koel/koel
synced 2025-01-21 00:44:05 +00:00
34 lines
960 B
PHP
34 lines
960 B
PHP
<?php
|
|
|
|
namespace E2E;
|
|
|
|
use Facebook\WebDriver\WebDriverBy;
|
|
use Facebook\WebDriver\WebDriverExpectedCondition;
|
|
|
|
class PlaylistScreenTest extends TestCase
|
|
{
|
|
use SongListActions;
|
|
|
|
public function testPlaylistScreen()
|
|
{
|
|
$this->loginAndWait()
|
|
->goto('songs')
|
|
->selectRange()
|
|
->createPlaylist('Bar');
|
|
|
|
$this->waitUntil(WebDriverExpectedCondition::textToBePresentInElement(
|
|
WebDriverBy::cssSelector('#playlists > ul'), 'Bar'
|
|
));
|
|
|
|
$this->click('#sidebar .playlist:nth-last-child(1)');
|
|
$this->waitUntil(WebDriverExpectedCondition::visibilityOfElementLocated(
|
|
WebDriverBy::id('playlistWrapper')
|
|
));
|
|
|
|
$this->click('#playlistWrapper .btn-delete-playlist');
|
|
// expect a confirmation
|
|
$this->waitUntil(WebDriverExpectedCondition::visibilityOfElementLocated(
|
|
WebDriverBy::cssSelector('.sweet-alert')
|
|
));
|
|
}
|
|
}
|