Skip to content
Permalink
Browse files

Merge branch '8.2'

  • Loading branch information...
sebastianbergmann committed Jul 5, 2019
2 parents 7bc0c63 + 72382b8 commit d22e27f57ad50491eafbaa7b14bb975da19e1199
@@ -2,6 +2,12 @@

All notable changes of the PHPUnit 8.2 release series are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles.

## [8.2.5] - 2019-MM-DD

### Fixed

* Fixed [#3747](https://github.com/sebastianbergmann/phpunit/pull/3747): Regression in `StringStartsWith` constraint

## [8.2.4] - 2019-07-03

### Changed
@@ -44,6 +50,7 @@ All notable changes of the PHPUnit 8.2 release series are documented in this fil

* Fixed [#3602](https://github.com/sebastianbergmann/phpunit/issues/3602): PHPUnit silently ignores the return value on a `void` method of test double

[8.2.5]: https://github.com/sebastianbergmann/phpunit/compare/8.2.4...8.2.5
[8.2.4]: https://github.com/sebastianbergmann/phpunit/compare/8.2.3...8.2.4
[8.2.3]: https://github.com/sebastianbergmann/phpunit/compare/8.2.2...8.2.3
[8.2.2]: https://github.com/sebastianbergmann/phpunit/compare/8.2.1...8.2.2
@@ -24,7 +24,7 @@ final class StringStartsWith extends Constraint
public function __construct(string $prefix)
{
if (empty($prefix)) {
if (\strlen($prefix) === 0) {
throw InvalidArgumentHelper::factory(1, 'non-empty string');
}
@@ -38,6 +38,13 @@ public function testConstraintStringStartsWithCorrectNumericValueAndReturnResult
$this->assertTrue($constraint->evaluate('0E1zzz', '', true));
}
public function testConstraintStringStartsWithCorrectSingleZeroAndReturnResult(): void
{
$constraint = new StringStartsWith('0');
$this->assertTrue($constraint->evaluate('0ABC', '', true));
}
public function testConstraintStringStartsWithNotCorrectNumericValueAndReturnResult(): void
{
$constraint = new StringStartsWith('0E1');

0 comments on commit d22e27f

Please sign in to comment.
You can’t perform that action at this time.