Skip to content

Commit

Permalink
CR fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
uuf6429 committed Jan 7, 2025
1 parent eed87e4 commit 75eac8b
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions src/WebdriverClassicDriver.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ class WebdriverClassicDriver extends CoreDriver
private const W3C_WINDOW_HANDLE_PREFIX = 'w3cwh:';

/**
* @var TWebDriver|null
* @phpstan-var TWebDriver|null
*/
private ?WebDriver $webDriver = null;

Expand Down Expand Up @@ -766,7 +766,7 @@ public function getBrowserName(): string
*/
public function getWebDriverSessionId(): ?string
{
return $this->isStarted() && method_exists($this->getWebDriver(), 'getSessionId')
return $this->isStarted() && method_exists($this->getWebDriver(), 'getSessionID')
? $this->getAsString($this->getWebDriver()->getSessionID(), 'Session ID')
: null;
}
Expand Down Expand Up @@ -804,7 +804,7 @@ protected function createWebDriver(): void
}

/**
* @return TWebDriver
* @phpstan-return TWebDriver
* @throws DriverException
*/
protected function getWebDriver(): WebDriver
Expand Down Expand Up @@ -988,7 +988,7 @@ private function executeJsOnXpath(
* $this->executeJsOnElement($element, 'return argument[0].childNodes.length');
* ```
*
* @param TWebDriverElement $element
* @phpstan-param TWebDriverElement $element
* @return mixed
* @throws DriverException
*/
Expand Down Expand Up @@ -1067,7 +1067,7 @@ private function getWindowHandleFromName(string $name): string
}

/**
* @param TWebDriverElement $element
* @phpstan-param TWebDriverElement $element
* @throws DriverException
*/
private function clickOnElement($element): void
Expand Down Expand Up @@ -1103,7 +1103,7 @@ private function withWindow(?string $name, callable $callback): void
}

/**
* @return TWebDriverElement
* @phpstan-return TWebDriverElement
* @throws DriverException
*/
private function findElement(
Expand All @@ -1121,7 +1121,7 @@ private function findElement(
}

/**
* @param TWebDriverElement $element
* @phpstan-param TWebDriverElement $element
* @throws DriverException
*/
private function selectRadioValue($element, string $value): void
Expand All @@ -1140,7 +1140,7 @@ private function selectRadioValue($element, string $value): void
}

/**
* @param TWebDriverElement $element
* @phpstan-param TWebDriverElement $element
* @throws DriverException
*/
private function selectOptionOnElement($element, string $value, bool $multiple = false): void
Expand Down Expand Up @@ -1171,7 +1171,7 @@ private function selectOptionOnElement($element, string $value, bool $multiple =
*
* Note: this implementation does not trigger a change event after deselecting the elements.
*
* @param TWebDriverElement $element
* @phpstan-param TWebDriverElement $element
* @throws DriverException
*/
private function deselectAllOptions($element): void
Expand All @@ -1189,7 +1189,7 @@ private function deselectAllOptions($element): void
}

/**
* @param TWebDriverElement $element
* @phpstan-param TWebDriverElement $element
* @throws DriverException
*/
private function ensureInputType(
Expand Down Expand Up @@ -1233,7 +1233,7 @@ private function jsonEncode($value, string $action, string $field): string
}

/**
* @param TWebDriverElement $element
* @phpstan-param TWebDriverElement $element
* @param mixed $value
* @throws DriverException
*/
Expand All @@ -1246,7 +1246,7 @@ private function setElementDomProperty($element, string $property, $value): void
}

/**
* @param TWebDriverElement $element
* @phpstan-param TWebDriverElement $element
* @return mixed
* @throws DriverException
*/
Expand Down

0 comments on commit 75eac8b

Please sign in to comment.