Skip to content

Commit

Permalink
Ignore command for updating version file from code coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
range-of-motion committed Dec 26, 2023
1 parent 0229d72 commit fc10c1c
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions app/Console/Commands/UpdateVersionFile.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ class UpdateVersionFile extends Command

protected $description = 'Updates the version in version.txt';

/**
* Ignoring this command from code coverage as it is dependent on whether Git is
* installed or not, which can vary from machine to machine.
*
* @codeCoverageIgnore
*/
public function handle(): int
{
if (trim(shell_exec('git rev-parse --is-inside-work-tree')) !== 'true') {
Expand Down

0 comments on commit fc10c1c

Please sign in to comment.