Skip to content

Commit

Permalink
Update e2e-tests.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
staabm committed Mar 13, 2024
1 parent c8f8981 commit 10e3621
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 5 deletions.
14 changes: 11 additions & 3 deletions .github/workflows/e2e-tests.yml
Expand Up @@ -227,15 +227,23 @@ jobs:
../../bin/phpstan analyse --configuration test-no-baseline.neon --generate-baseline test-baseline.neon
../../bin/phpstan analyse --configuration test.neon
- script: |
cd e2e/composer-min-version
cd e2e/composer-max-version
composer install
../../bin/phpstan analyze test.php
- script: |
cd e2e/composer-max-version
cd e2e/composer-min-max-version
composer install
../../bin/phpstan analyze test.php
- script: |
cd e2e/composer-min-max-version
cd e2e/composer-min-open-end-version
composer install
../../bin/phpstan analyze test.php
- script: |
cd e2e/composer-min-version
composer install
../../bin/phpstan analyze test.php
- script: |
cd e2e/composer-version-config
composer install
../../bin/phpstan analyze test.php
Expand Down
6 changes: 4 additions & 2 deletions src/Php/ComposerPhpVersionFactory.php
Expand Up @@ -53,9 +53,11 @@ public function __construct(
if ($this->minVersion === null && !$constraint->getLowerBound()->isZero()) {
$this->minVersion = $this->buildVersion($constraint->getLowerBound()->getVersion());
}
if ($this->maxVersion === null && !$constraint->getUpperBound()->isPositiveInfinity()) {
$this->maxVersion = $this->buildVersion($constraint->getUpperBound()->getVersion());
if ($this->maxVersion !== null || $constraint->getUpperBound()->isPositiveInfinity()) {
return;
}

$this->maxVersion = $this->buildVersion($constraint->getUpperBound()->getVersion());
}

public function getMinVersion(): ?PhpVersion
Expand Down

0 comments on commit 10e3621

Please sign in to comment.