Skip to content

Commit

Permalink
Skip tests
Browse files Browse the repository at this point in the history
  • Loading branch information
uuf6429 committed Mar 7, 2024
1 parent 6ba6cc1 commit 48e300c
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions tests/WebdriverClassicConfig.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public function mapRemoteFilePath($file): string
public function skipMessage($testCase, $test): ?string
{
switch (true) {
case $testCase === WindowTest::class && $test === 'testWindowMaximize' && $this->isXvfb():
case [$testCase, $test] === [WindowTest::class, 'testWindowMaximize'] && $this->isXvfb():
return 'Maximizing the window does not work when running the browser in Xvfb.';

case $testCase === BasicAuthTest::class:
Expand All @@ -52,9 +52,16 @@ public function skipMessage($testCase, $test): ?string
case $testCase === StatusCodeTest::class:
return 'Checking status code is not supported.';

case $testCase === EventsTest::class && $test === 'testKeyboardEvents' && $this->isOldChrome():
case [$testCase, $test] === [EventsTest::class, 'testKeyboardEvents'] && $this->isOldChrome():
return 'Old Chrome does not allow triggering events.';

case [$testCase, $test] === [EventsTest::class, 'testBlur']:
case [$testCase, $test] === [EventsTest::class, 'testFocus']:
return 'Focus/blur are not supported anymore.';

case [$testCase, $test] === [EventsTest::class, 'testKeyboardEvents']:
return 'Keyboard events are currently not supported.';

default:
return parent::skipMessage($testCase, $test);
}
Expand Down

0 comments on commit 48e300c

Please sign in to comment.