Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
taylorotwell committed Jul 24, 2023
1 parent 2b44d8c commit 806b1fc
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 23 deletions.
34 changes: 17 additions & 17 deletions src/Console/ChromeDriverCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -245,21 +245,7 @@ protected function rename($binary, $os)
}

/**
* Get the contents of a URL using the 'proxy' and 'ssl-no-verify' command options.
*
* @return string
*/
protected function getUrl(string $url)
{
return Http::withOptions(array_merge([
'verify' => $this->option('ssl-no-verify') === false,
]), array_filter([
'proxy' => $this->option('proxy'),
]))->get($url)->body();
}

/**
* Get the chrome version from URL.
* Get the Chrome version from URL.
*
* @return string
*/
Expand All @@ -271,7 +257,7 @@ protected function fetchChromeVersionFromUrl(int $version)
}

/**
* Get the chrome versions per milestone.
* Get the Chrome versions per milestone.
*
* @return array
*/
Expand All @@ -283,7 +269,7 @@ protected function resolveChromeVersionsPerMilestone()
}

/**
* Resolve the download url.
* Resolve the download URL.
*
* @return string
*
Expand All @@ -308,4 +294,18 @@ protected function resolveChromeDriverDownloadUrl(string $version, string $os)
return collect($chromedrivers)->firstWhere('platform', $slug)['url']
?? throw new Exception('Could not get the ChromeDriver version.');
}

/**
* Get the contents of a URL using the 'proxy' and 'ssl-no-verify' command options.
*
* @return string
*/
protected function getUrl(string $url)
{
return Http::withOptions(array_merge([
'verify' => $this->option('ssl-no-verify') === false,
]), array_filter([
'proxy' => $this->option('proxy'),
]))->get($url)->body();
}
}
12 changes: 6 additions & 6 deletions src/OperatingSystem.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
class OperatingSystem
{
/**
* List of available Operating System platforms.
* List of available operating system platforms.
*
* @var array<string, array{slug: string, commands: array<int, string>}>
*/
Expand Down Expand Up @@ -52,7 +52,7 @@ class OperatingSystem
];

/**
* Resolve Chrome version commands.
* Resolve the Chrome version commands for the given operating system.
*
* @param string $operatingSystem
* @return array<int, string>
Expand All @@ -69,7 +69,7 @@ public static function chromeVersionCommands($operatingSystem)
}

/**
* Resolve ChromeDriver slug.
* Resolve the ChromeDriver slug for the given operating system.
*
* @param string $operatingSystem
* @param string|null $version
Expand All @@ -95,7 +95,7 @@ public static function chromeDriverSlug($operatingSystem, $version = null)
}

/**
* Returns all possible OS.
* Get all supported operating systems.
*
* @return array<int, string>
*/
Expand All @@ -105,7 +105,7 @@ public static function all()
}

/**
* Returns the current OS identifier.
* Get the current operating system identifier.
*
* @return string
*/
Expand Down Expand Up @@ -141,7 +141,7 @@ public static function onMac()
}

/**
* Mac platform architecture.
* Get the current macOS platform architecture.
*
* @return string
*/
Expand Down

0 comments on commit 806b1fc

Please sign in to comment.