Skip to content

Commit

Permalink
dismiss gutenberg nux tooltips
Browse files Browse the repository at this point in the history
  • Loading branch information
Adam Silverstein committed Apr 2, 2019
1 parent 714a9a5 commit 5f905cc
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
13 changes: 13 additions & 0 deletions tests/wpacceptance/PushMenuTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,13 @@ public function testConnectionCrossOutOnPush() {
$I->click( '#distributor-push-wrapper .new-connections-list .add-connection[data-connection-id="2"]' );

usleep( 500 );
try {
if ( $I->getElement( '.nux-dot-tip__disable' ) ) {
$I->click( '.nux-dot-tip__disable' );
}
} catch ( \Exception $e ) {}

$I->takeScreenshot( 'screenshots/testConnectionCrossOutOnPush' );

// Distribute post (as draft)
$I->click( '#distributor-push-wrapper .syndicate-button' );
Expand All @@ -71,6 +78,12 @@ public function testSelectConnection() {

$I->waitUntilElementVisible( '#wp-admin-bar-distributor a' );

try {
if ( $I->getElement( '.nux-dot-tip__disable' ) ) {
$I->click( '.nux-dot-tip__disable' );
}
} catch ( \Exception $e ) {}

$I->moveMouse( '#wp-admin-bar-distributor a' );

$I->click( '#wp-admin-bar-distributor a' );
Expand Down
3 changes: 1 addition & 2 deletions tests/wpacceptance/includes/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,7 @@ protected function pushPost( \WPAcceptance\PHPUnit\Actor $I, $post_id, $to_conne
if ( $I->getElement( '.nux-dot-tip__disable' ) ) {
$I->click( '.nux-dot-tip__disable' );
}
} catch ( \Exception $e ) {
}
} catch ( \Exception $e ) {}

$I->moveMouse( '#wp-admin-bar-distributor a' );

Expand Down

0 comments on commit 5f905cc

Please sign in to comment.