prefix stringlengths 512 512 | suffix stringlengths 256 256 | middle stringlengths 14 229 | meta dict |
|---|---|---|---|
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event;
use PHPUnit\Event\Tracer\Tracer;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\F... | ck(SubscribableDispatcher::class);
$subscribableDispatcher
->expects($this->never())
->method('dispatch')
->seal();
$deferringDispatcher = new DeferringDispatcher($subscribableDispatcher);
$def |
#[Group('event-system')]
#[Group('event-system/dispatcher')]
final class DeferringDispatcherTest extends TestCase
{
public function testCollectsEventsUntilFlush(): void
{
$subscribableDispatcher = $this->createMo | {
"filepath": "tests/unit/Event/Dispatcher/DeferringDispatcherTest.php",
"language": "php",
"file_size": 2738,
"cut_index": 563,
"middle_length": 229
} |
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Runtime;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\... | st extends TestCase
{
public function testHasVersionId(): void
{
$this->assertSame(Version::id(), (new PHPUnit)->versionId());
}
public function testHasReleaseSeries(): void
{
$this->assertSame(Version::series(), (new P | 'event-system/value-objects')]
final class PHPUnitTe | {
"filepath": "tests/unit/Event/Value/Runtime/PHPUnitTest.php",
"language": "php",
"file_size": 890,
"cut_index": 547,
"middle_length": 52
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Code;
use PHPUnit\Event\TestData\TestDataCollection;
use PHPUnit\Fr... | eatedFromArray(): void
{
$test = $this->test();
$tests = TestCollection::fromArray([$test]);
$this->assertSame([$test], $tests->asArray());
}
public function testIsCountable(): void
{
$test = $this->test( | rsClass(TestCollection::class)]
#[CoversClass(TestCollectionIterator::class)]
#[Small]
#[Group('event-system')]
#[Group('event-system/value-objects')]
final class TestCollectionTest extends TestCase
{
public function testIsCr | {
"filepath": "tests/unit/Event/Value/Test/TestCollectionTest.php",
"language": "php",
"file_size": 1760,
"cut_index": 537,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\TestSuite;
use PHPUnit\Event\AbstractEventTestCase;
us... | testSuiteValueObject();
$event = new Filtered(
$telemetryInfo,
$testSuite,
);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($testSuite, $event->testSuite());
}
| [Group('event-system/events')]
final class FilteredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$testSuite = $this-> | {
"filepath": "tests/unit/Event/Events/TestSuite/FilteredTest.php",
"language": "php",
"file_size": 1284,
"cut_index": 524,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | $test = $this->testValueObject();
$calledMethods = $this->calledMethods();
$event = new PostConditionFinished(
$telemetryInfo,
$test,
...$calledMethods,
);
$this->assert | ('event-system')]
#[Group('event-system/events')]
final class PostConditionFinishedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
| {
"filepath": "tests/unit/Event/Events/Test/HookMethod/PostConditionFinishedTest.php",
"language": "php",
"file_size": 1932,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | $test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$event = new PreConditionCalled(
$telemetryInfo,
$test,
$calledMethod,
);
$this->assertSame($telemetr | vent-system')]
#[Group('event-system/events')]
final class PreConditionCalledTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
| {
"filepath": "tests/unit/Event/Events/Test/HookMethod/PreConditionCalledTest.php",
"language": "php",
"file_size": 1644,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | tryInfo();
$test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new PreConditionErrored(
$telemetryI | mall]
#[Group('event-system')]
#[Group('event-system/events')]
final class PreConditionErroredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->teleme | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/PreConditionErroredTest.php",
"language": "php",
"file_size": 1982,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | yInfo();
$test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new PreConditionFailed(
$telemetryInfo | all]
#[Group('event-system')]
#[Group('event-system/events')]
final class PreConditionFailedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetr | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/PreConditionFailedTest.php",
"language": "php",
"file_size": 1977,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | $test = $this->testValueObject();
$calledMethods = $this->calledMethods();
$event = new PreConditionFinished(
$telemetryInfo,
$test,
...$calledMethods,
);
$this->assertSam | 'event-system')]
#[Group('event-system/events')]
final class PreConditionFinishedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
| {
"filepath": "tests/unit/Event/Events/Test/HookMethod/PreConditionFinishedTest.php",
"language": "php",
"file_size": 1927,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | this->telemetryInfo();
$testMethod = new ClassMethod('ClassTest', 'testOne');
$dataProviderMethod = new ClassMethod('ClassTest', 'dataProvider');
$event = new DataProviderMethodCalled(
$telemetryInfo,
| [Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class DataProviderMethodCalledTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $ | {
"filepath": "tests/unit/Event/Events/Test/Lifecycle/DataProviderMethodCalledTest.php",
"language": "php",
"file_size": 1713,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | = $this->telemetryInfo();
$testMethod = new ClassMethod('ClassTest', 'testOne');
$dataProviderMethod = new ClassMethod('ClassTest', 'dataProvider');
$event = new DataProviderMethodFinished(
$telemetryInfo,
|
#[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class DataProviderMethodFinishedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo | {
"filepath": "tests/unit/Event/Events/Test/Lifecycle/DataProviderMethodFinishedTest.php",
"language": "php",
"file_size": 1801,
"cut_index": 537,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHP... | alueObject();
$event = new Finished(
$telemetryInfo,
$test,
1,
);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($test, $event->test());
$this->ass | p('event-system/events')]
final class FinishedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test = $this->testV | {
"filepath": "tests/unit/Event/Events/Test/Lifecycle/FinishedTest.php",
"language": "php",
"file_size": 1353,
"cut_index": 524,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use const PHP_EOL;
use Exception;
use PHPUnit\Event\AbstractE... | $telemetryInfo = $this->telemetryInfo();
$test = $this->testValueObject();
$throwable = ThrowableBuilder::from(new Exception('message'));
$event = new PreparationErrored(
$telemetryInfo,
$te | ass(PreparationErrored::class)]
#[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class PreparationErroredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
| {
"filepath": "tests/unit/Event/Events/Test/Lifecycle/PreparationErroredTest.php",
"language": "php",
"file_size": 1623,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use const PHP_EOL;
use Exception;
use PHPUnit\Event\AbstractE... | $telemetryInfo = $this->telemetryInfo();
$test = $this->testValueObject();
$throwable = ThrowableBuilder::from(new Exception('message'));
$event = new PreparationFailed(
$telemetryInfo,
$test, | ass(PreparationFailed::class)]
#[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class PreparationFailedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
| {
"filepath": "tests/unit/Event/Events/Test/Lifecycle/PreparationFailedTest.php",
"language": "php",
"file_size": 1618,
"cut_index": 537,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHP... | = $this->testValueObject();
$event = new PreparationStarted(
$telemetryInfo,
$test,
);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($test, $event->test());
| ')]
#[Group('event-system/events')]
final class PreparationStartedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test | {
"filepath": "tests/unit/Event/Events/Test/Lifecycle/PreparationStartedTest.php",
"language": "php",
"file_size": 1305,
"cut_index": 524,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHP... | alueObject();
$event = new Prepared(
$telemetryInfo,
$test,
);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($test, $event->test());
}
public function testCa | p('event-system/events')]
final class PreparedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test = $this->testV | {
"filepath": "tests/unit/Event/Events/Test/Lifecycle/PreparedTest.php",
"language": "php",
"file_size": 1254,
"cut_index": 524,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | = $this->testValueObject();
$throwable = $this->throwable();
$event = new Errored(
$telemetryInfo,
$test,
$throwable,
);
$this->assertSame($telemetryInfo, $event->telemetry | p('event-system')]
#[Group('event-system/events')]
final class ErroredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test | {
"filepath": "tests/unit/Event/Events/Test/Outcome/ErroredTest.php",
"language": "php",
"file_size": 1664,
"cut_index": 537,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Code;
use PHP... | o();
$test = $this->testValueObject();
$throwable = $this->throwable();
$comparisonFailure = $this->comparisonFailure();
$event = new Failed(
$telemetryInfo,
$test,
$ | #[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class FailedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInf | {
"filepath": "tests/unit/Event/Events/Test/Outcome/FailedTest.php",
"language": "php",
"file_size": 2643,
"cut_index": 563,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | o();
$test = $this->testValueObject();
$throwable = $this->throwable();
$event = new MarkedIncomplete(
$telemetryInfo,
$test,
$throwable,
);
$this->assertSame($telem | l]
#[Group('event-system')]
#[Group('event-system/events')]
final class MarkedIncompleteTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInf | {
"filepath": "tests/unit/Event/Events/Test/Outcome/MarkedIncompleteTest.php",
"language": "php",
"file_size": 1720,
"cut_index": 537,
"middle_length": 229
} |
declare(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
u... | tValueObject();
$event = new Passed(
$telemetryInfo,
$test,
);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($test, $event->test());
}
public function testCa | Group('event-system/events')]
final class PassedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test = $this->tes | {
"filepath": "tests/unit/Event/Events/Test/Outcome/PassedTest.php",
"language": "php",
"file_size": 1244,
"cut_index": 518,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHP... | ueObject();
$message = 'skipped';
$event = new Skipped(
$telemetryInfo,
$test,
$message,
);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($t | ('event-system/events')]
final class SkippedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test = $this->testVal | {
"filepath": "tests/unit/Event/Events/Test/Outcome/SkippedTest.php",
"language": "php",
"file_size": 1473,
"cut_index": 524,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Framewor... | ValueObject();
$message = 'message';
$event = new ConsideredRisky(
$telemetryInfo,
$test,
$message,
);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertS | nt-system/events')]
final class ConsideredRiskyTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test = $this->test | {
"filepath": "tests/unit/Event/Events/Test/Issue/ConsideredRiskyTest.php",
"language": "php",
"file_size": 1509,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | etryInfo();
$testClassName = 'Test';
$calledMethod = $this->calledMethod();
$event = new BeforeFirstTestMethodCalled(
$telemetryInfo,
$testClassName,
$calledMethod,
);
$this->as | [Group('event-system')]
#[Group('event-system/events')]
final class BeforeFirstTestMethodCalledTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telem | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/BeforeFirstTestMethodCalledTest.php",
"language": "php",
"file_size": 1675,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | fo = $this->telemetryInfo();
$testClassName = 'Test';
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new BeforeFirstTestMethodErrored(
$t | ass)]
#[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class BeforeFirstTestMethodErroredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryIn | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/BeforeFirstTestMethodErroredTest.php",
"language": "php",
"file_size": 2013,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | ;
$test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$event = new BeforeTestMethodCalled(
$telemetryInfo,
$test,
$calledMethod,
);
$this->assertSa | p('event-system')]
#[Group('event-system/events')]
final class BeforeTestMethodCalledTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo() | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/BeforeTestMethodCalledTest.php",
"language": "php",
"file_size": 1658,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | ->telemetryInfo();
$test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new BeforeTestMethodErrored(
|
#[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class BeforeTestMethodErroredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/BeforeTestMethodErroredTest.php",
"language": "php",
"file_size": 1996,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | fo();
$test = $this->testValueObject();
$calledMethods = $this->calledMethods();
$event = new BeforeTestMethodFinished(
$telemetryInfo,
$test,
...$calledMethods,
);
$thi | oup('event-system')]
#[Group('event-system/events')]
final class BeforeTestMethodFinishedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryIn | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/BeforeTestMethodFinishedTest.php",
"language": "php",
"file_size": 1941,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | tryInfo();
$test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new PostConditionFailed(
$telemetryI | mall]
#[Group('event-system')]
#[Group('event-system/events')]
final class PostConditionFailedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->teleme | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/PostConditionFailedTest.php",
"language": "php",
"file_size": 1982,
"cut_index": 537,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\TestRunner\Issue;
use const PHP_EOL;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Fra... | = 'message';
$file = 'file';
$line = 1;
$suppressed = false;
$ignoredByBaseline = false;
$event = new WarningTriggered(
$telemetryInfo,
$message,
| p('event-system/events')]
final class WarningTriggeredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$message | {
"filepath": "tests/unit/Event/Events/TestRunner/Issue/WarningTriggeredTest.php",
"language": "php",
"file_size": 2477,
"cut_index": 563,
"middle_length": 229
} |
declare(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\TestSuite;
use PHPUnit\Event\AbstractEventTestCa... | ->testSuiteValueObject();
$event = new Loaded($telemetryInfo, $testSuite);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($testSuite, $event->testSuite());
}
public function testCanBeReprese | )]
#[Group('event-system/events')]
final class LoadedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$testSuite = $this | {
"filepath": "tests/unit/Event/Events/TestSuite/LoadedTest.php",
"language": "php",
"file_size": 1239,
"cut_index": 518,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\TestSuite;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Fra... | $executionOrderDefects = 5;
$resolveDependencies = true;
$event = new Sorted(
$telemetryInfo,
$executionOrder,
$executionOrderDefects,
$resolveDependencies,
);
$this- | ystem/events')]
final class SortedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$executionOrder = 9001;
| {
"filepath": "tests/unit/Event/Events/TestSuite/SortedTest.php",
"language": "php",
"file_size": 1584,
"cut_index": 537,
"middle_length": 229
} |
declare(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\TestSuite;
use PHPUnit\Event\AbstractEventTestCa... | is->testSuiteValueObject();
$event = new Started($telemetryInfo, $testSuite);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($testSuite, $event->testSuite());
}
public function testCanBeRepr | ')]
#[Group('event-system/events')]
final class StartedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$testSuite = $th | {
"filepath": "tests/unit/Event/Events/TestSuite/StartedTest.php",
"language": "php",
"file_size": 1249,
"cut_index": 518,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Framewor... | $test = $this->testValueObject();
$additionalInformation = 'additional information';
$event = new AdditionalInformationProvided(
$telemetryInfo,
$test,
$additionalInformation,
| ]
#[Group('event-system/events')]
final class AdditionalInformationProvidedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
| {
"filepath": "tests/unit/Event/Events/Test/AdditionalInformationProvidedTest.php",
"language": "php",
"file_size": 1690,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | nfo = $this->telemetryInfo();
$test = $this->testValueObject();
$customTestMethodInvocation = $this->calledMethod();
$event = new CustomTestMethodInvocationUsed(
$telemetryInfo,
| ss)]
#[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class CustomTestMethodInvocationUsedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryI | {
"filepath": "tests/unit/Event/Events/Test/CustomTestMethodInvocationUsedTest.php",
"language": "php",
"file_size": 1866,
"cut_index": 537,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHP... | $output = 'output';
$event = new PrintedUnexpectedOutput(
$telemetryInfo,
$output,
);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($output, $event->output()) | ystem')]
#[Group('event-system/events')]
final class PrintedUnexpectedOutputTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
| {
"filepath": "tests/unit/Event/Events/Test/PrintedUnexpectedOutputTest.php",
"language": "php",
"file_size": 1385,
"cut_index": 524,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | this->telemetryInfo();
$testClassName = 'Test';
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new AfterLastTestMethodFailed(
$telemetryI | )]
#[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class AfterLastTestMethodFailedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $ | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/AfterLastTestMethodFailedTest.php",
"language": "php",
"file_size": 2009,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | etryInfo();
$testClassName = 'Test';
$calledMethods = $this->calledMethods();
$event = new AfterLastTestMethodFinished(
$telemetryInfo,
$testClassName,
...$calledMethods,
);
$thi | [Group('event-system')]
#[Group('event-system/events')]
final class AfterLastTestMethodFinishedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telem | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/AfterLastTestMethodFinishedTest.php",
"language": "php",
"file_size": 1966,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | telemetryInfo();
$test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new AfterTestMethodErrored(
$t | #[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class AfterTestMethodErroredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this-> | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/AfterTestMethodErroredTest.php",
"language": "php",
"file_size": 1991,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | = $this->telemetryInfo();
$testClassName = 'Test';
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new BeforeFirstTestMethodFailed(
$tele | ss)]
#[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class BeforeFirstTestMethodFailedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/BeforeFirstTestMethodFailedTest.php",
"language": "php",
"file_size": 2008,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | elemetryInfo();
$testClassName = 'Test';
$calledMethods = $this->calledMethods();
$event = new BeforeFirstTestMethodFinished(
$telemetryInfo,
$testClassName,
...$calledMethods,
);
|
#[Group('event-system')]
#[Group('event-system/events')]
final class BeforeFirstTestMethodFinishedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->t | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/BeforeFirstTestMethodFinishedTest.php",
"language": "php",
"file_size": 1958,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | telemetryInfo();
$test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new BeforeTestMethodFailed(
$t | #[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class BeforeTestMethodFailedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this-> | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/BeforeTestMethodFailedTest.php",
"language": "php",
"file_size": 1991,
"cut_index": 537,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\TestSuite;
use PHPUnit\Event\AbstractEventTestCase;
us... | testSuiteValueObject();
$event = new Finished(
$telemetryInfo,
$testSuite,
);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($testSuite, $event->testSuite());
}
| [Group('event-system/events')]
final class FinishedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$testSuite = $this-> | {
"filepath": "tests/unit/Event/Events/TestSuite/FinishedTest.php",
"language": "php",
"file_size": 1289,
"cut_index": 524,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\TestSuite;
use PHPUnit\Event\AbstractEventTestCase;
us... | stSuiteValueObject();
$message = 'the-message';
$event = new Skipped($telemetryInfo, $testSuite, $message);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($testSuite, $event->testSuite( | Group('event-system/events')]
final class SkippedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$testSuite = $this->te | {
"filepath": "tests/unit/Event/Events/TestSuite/SkippedTest.php",
"language": "php",
"file_size": 1383,
"cut_index": 524,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHP... | sName = 'ClassName';
$event = new ComparatorRegistered(
$telemetryInfo,
$className,
);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($className, $event->className | em')]
#[Group('event-system/events')]
final class ComparatorRegisteredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$clas | {
"filepath": "tests/unit/Event/Events/Test/ComparatorRegisteredTest.php",
"language": "php",
"file_size": 1292,
"cut_index": 524,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | $this->telemetryInfo();
$testClassName = 'Test';
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new AfterLastTestMethodErrored(
$telemet | s)]
#[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class AfterLastTestMethodErroredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/AfterLastTestMethodErroredTest.php",
"language": "php",
"file_size": 2014,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | $test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$event = new AfterTestMethodCalled(
$telemetryInfo,
$test,
$calledMethod,
);
$this->assertSame( | ('event-system')]
#[Group('event-system/events')]
final class AfterTestMethodCalledTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
| {
"filepath": "tests/unit/Event/Events/Test/HookMethod/AfterTestMethodCalledTest.php",
"language": "php",
"file_size": 1653,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | ();
$test = $this->testValueObject();
$calledMethods = $this->calledMethods();
$event = new AfterTestMethodFinished(
$telemetryInfo,
$test,
...$calledMethods,
);
$this-> | up('event-system')]
#[Group('event-system/events')]
final class AfterTestMethodFinishedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/AfterTestMethodFinishedTest.php",
"language": "php",
"file_size": 1936,
"cut_index": 537,
"middle_length": 229
} |
declare(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Application;
use PHPUnit\Event\AbstractEventTest... | 0;
$event = new Finished($telemetryInfo, $shellExitCode);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($shellExitCode, $event->shellExitCode());
}
public function testCanBeRepresentedAsSt | tem')]
#[Group('event-system/events')]
final class FinishedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$shellExitCode = | {
"filepath": "tests/unit/Event/Events/Application/FinishedTest.php",
"language": "php",
"file_size": 1177,
"cut_index": 518,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | Info();
$testClassName = 'Test';
$calledMethod = $this->calledMethod();
$event = new AfterLastTestMethodCalled(
$telemetryInfo,
$testClassName,
$calledMethod,
);
$this->assertSa | roup('event-system')]
#[Group('event-system/events')]
final class AfterLastTestMethodCalledTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetry | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/AfterLastTestMethodCalledTest.php",
"language": "php",
"file_size": 1676,
"cut_index": 537,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use const PHP_EOL;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Framework\Attri... | estValueObject();
$message = 'message';
$file = 'file';
$line = 1;
$suppressed = false;
$ignoredByBaseline = false;
$event = new WarningTriggered(
$tele | tem/events')]
final class WarningTriggeredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test = $this->t | {
"filepath": "tests/unit/Event/Events/Test/Issue/WarningTriggeredTest.php",
"language": "php",
"file_size": 2727,
"cut_index": 563,
"middle_length": 229
} |
clare(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner;
use PHPUnit\Framework\Attributes\CoversClass;
us... | ion testCanRegisterAndRestoreForNonTestCaseContext(): void
{
$errorHandler = ErrorHandler::instance();
$errorHandler->registerForNonTestCaseContext();
$errorHandler->restoreForNonTestCaseContext();
$this->assertTrue(tru | ErrorHandlerTest extends TestCase
{
public funct | {
"filepath": "tests/unit/Runner/ErrorHandlerTest.php",
"language": "php",
"file_size": 840,
"cut_index": 520,
"middle_length": 52
} |
;
use PHPUnit\Event\Test\ErrorTriggered;
use PHPUnit\Event\Test\NoticeTriggered;
use PHPUnit\Event\Test\PhpDeprecationTriggered;
use PHPUnit\Event\Test\PhpNoticeTriggered;
use PHPUnit\Event\Test\PhpWarningTriggered;
use PHPUnit\Event\Test\WarningTriggered;
use PHPUnit\Event\TestData\TestDataCollection;
use PHPUnit\Fram... | ssueFilterTest extends TestCase
{
public function testProcessesDeprecationByDefault(): void
{
$filter = new IssueFilter($this->source());
$this->assertTrue(
$filter->shouldBeProcessed($this->deprecationEvent()),
| it\TextUI\Configuration\FilterDirectoryCollection;
use PHPUnit\TextUI\Configuration\FilterFileCollection;
use PHPUnit\TextUI\Configuration\Source;
#[CoversClass(IssueFilter::class)]
#[Small]
#[Group('test-runner')]
final class I | {
"filepath": "tests/unit/Runner/IssueFilterTest.php",
"language": "php",
"file_size": 19521,
"cut_index": 1331,
"middle_length": 229
} |
Framework\DataProviderTestSuite;
use PHPUnit\Framework\TestCase;
use PHPUnit\Framework\TestStatus\TestStatus;
use PHPUnit\Framework\TestSuite;
use PHPUnit\Runner\ResultCache\DefaultResultCache;
use PHPUnit\Runner\ResultCache\ResultCacheId;
use PHPUnit\TestFixture\LargeGroupAttributesTest;
use PHPUnit\TestFixture\Medium... | tesTest('testOne');
$small = new SmallGroupAttributesTest('testOne');
$medium = new MediumGroupAttributesTest('testOne');
$suite = TestSuite::empty('test');
$suite->setTests([$large, $small, $medium]);
$sorter = n | versClass(TestSuiteSorter::class)]
#[CoversClass(DataProviderTestSuite::class)]
#[Small]
final class TestSuiteSorterTest extends TestCase
{
public function testSortsBySize(): void
{
$large = new LargeGroupAttribu | {
"filepath": "tests/unit/Runner/TestSuiteSorterTest.php",
"language": "php",
"file_size": 12607,
"cut_index": 921,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Filter;
use Exception;
use PHPUnit\Framework\Attribut... | c function testCaseSensitiveMatch(): void
{
$this->assertTrue($this->createFilter('NotMatchingPattern')->accept());
}
/**
* @throws Exception
*/
public function testCaseInsensitiveMatch(): void
{
$this->assert | ountTest;
#[CoversClass(ExcludeNameFilterIterator::class)]
#[Small]
#[Group('test-runner')]
#[Group('test-runner/filter')]
class ExcludeNameFilterIteratorTest extends TestCase
{
/**
* @throws Exception
*/
publi | {
"filepath": "tests/unit/Runner/Filter/ExcludeNameFilterIteratorTest.php",
"language": "php",
"file_size": 1482,
"cut_index": 524,
"middle_length": 229
} |
tian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Filter;
use Exception;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Group;
use PHPUnit\Framework\Attributes\S... | {
$this->assertTrue($this->createFilter('BankAccountTest')->accept());
}
/**
* @throws Exception
*/
public function testCaseInsensitiveMatch(): void
{
$this->assertTrue($this->createFilter('bankaccounttest')-> | or::class)]
#[Small]
#[Group('test-runner')]
#[Group('test-runner/filter')]
final class IncludeNameFilterIteratorTest extends TestCase
{
/**
* @throws Exception
*/
public function testCaseSensitiveMatch(): void
| {
"filepath": "tests/unit/Runner/Filter/IncludeNameFilterIteratorTest.php",
"language": "php",
"file_size": 3882,
"cut_index": 614,
"middle_length": 229
} |
tian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Filter;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\Attributes\Group;
us... | thodNamePortion(): array
{
return [
'plain method name' => ['testFoo', '{testFoo}i'],
'with numeric data set index' => ['testFoo#0', '{testFoo}i | ]
#[Group('test-runner/filter')]
final class MethodNameFilterCompilerTest extends TestCase
{
/**
* @return non-empty-list<array{non-empty-string, non-empty-string}>
*/
public static function provideFiltersWithMe | {
"filepath": "tests/unit/Runner/Filter/MethodNameFilterCompilerTest.php",
"language": "php",
"file_size": 3095,
"cut_index": 614,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Filter;
use function assert;
use Iterator;
use PHPUnit\Framework\A... | terIteratorTest extends TestCase
{
public function testAcceptsTestsBasedOnTheirId(): void
{
$id = 'PHPUnit\TestFixture\BankAccountTest::testBalanceCannotBecomeNegative';
foreach ($this->testSuiteIterator([$id]) as $test) {
| stSuiteIterator;
use PHPUnit\TestFixture\BankAccountTest;
#[CoversClass(TestIdFilterIterator::class)]
#[CoversClass(TestSuiteIterator::class)]
#[Small]
#[Group('test-runner')]
#[Group('test-runner/filter')]
final class TestIdFil | {
"filepath": "tests/unit/Runner/Filter/TestIdFilterIteratorTest.php",
"language": "php",
"file_size": 1876,
"cut_index": 537,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Extension;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Gr... | d
{
$facade = new ExtensionFacade;
$facade->replaceOutput();
$this->assertTrue($facade->replacesOutput());
}
public function testDoesNotReplaceProgressOutputByDefault(): void
{
$facade = new ExtensionFacad | stCase
{
public function testDoesNotReplaceOutputByDefault(): void
{
$facade = new ExtensionFacade;
$this->assertFalse($facade->replacesOutput());
}
public function testOutputCanBeReplaced(): voi | {
"filepath": "tests/unit/Runner/Extension/ExtensionFacadeTest.php",
"language": "php",
"file_size": 2623,
"cut_index": 563,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Extension;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUn... | ParameterCollection::fromArray(['key' => 'value']);
$this->assertTrue($parameters->has('key'));
}
public function testReportsWhetherParameterExists(): void
{
$parameters = ParameterCollection::fromArray(['key' => 'value']);
| ass)]
#[CoversClass(ParameterDoesNotExistException::class)]
#[Small]
#[Group('test-runner')]
final class ParameterCollectionTest extends TestCase
{
public function testCanBeCreatedFromArray(): void
{
$parameters = | {
"filepath": "tests/unit/Runner/Extension/ParameterCollectionTest.php",
"language": "php",
"file_size": 1715,
"cut_index": 537,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Phpt;
use PHPUnit\Framework\Attributes\CoversClass;
u... |
$exception = new PhptExternalFileCannotBeLoadedException('FILE', '/path/to/missing.php');
$this->assertSame(
'Could not load --FILE_EXTERNAL-- /path/to/missing.php for PHPT file',
$exception->getMessage(),
| upportedPhptSectionException::class)]
#[Small]
#[Group('test-runner')]
#[Group('test-runner/phpt')]
final class ExceptionTest extends TestCase
{
public function testPhptExternalFileCannotBeLoadedExceptionMessage(): void
{ | {
"filepath": "tests/unit/Runner/Phpt/ExceptionTest.php",
"language": "php",
"file_size": 1308,
"cut_index": 524,
"middle_length": 229
} |
tian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Phpt;
use function glob;
use function realpath;
use function str_replace;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\A... | pty-string, array{0: non-empty-string}>
*/
public static function unsupportedSections(): array
{
$data = [];
foreach (glob(__DIR__ . '/../../../_files/phpt/unsupported/*.phpt') as $file) {
$data[str_replace([__DIR_ | (Parser::class)]
#[CoversClass(PhptExternalFileCannotBeLoadedException::class)]
#[Small]
#[Group('test-runner')]
#[Group('test-runner/phpt')]
final class ParserTest extends TestCase
{
/**
* @return non-empty-array<non-em | {
"filepath": "tests/unit/Runner/Phpt/ParserTest.php",
"language": "php",
"file_size": 4557,
"cut_index": 614,
"middle_length": 229
} |
tian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Phpt;
use function file_exists;
use function sys_get_temp_dir;
use function tempnam;
use function unlink;
use PHPUnit\Framework\Attributes\Cove... | )) {
@unlink($file);
}
}
}
public function testRenderReplacesFileAndDirConstants(): void
{
$renderer = new Renderer;
$result = $renderer->render(
'/path/to/test.phpt',
| up('test-runner/phpt')]
final class RendererTest extends TestCase
{
private array $tempFiles = [];
protected function tearDown(): void
{
foreach ($this->tempFiles as $file) {
if (file_exists($file | {
"filepath": "tests/unit/Runner/Phpt/RendererTest.php",
"language": "php",
"file_size": 4064,
"cut_index": 614,
"middle_length": 229
} |
hp declare(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Phpt;
use function realpath;
use PHPUnit\Fra... | /_files/success.phpt');
$testCase = new TestCase($filename);
$this->assertSame($filename, $testCase->sortId());
}
public function testCountReturnsOne(): void
{
$filename = realpath(__DIR__ . '/../../../_files/success.p | ss)]
#[Small]
#[Group('test-runner')]
#[Group('test-runner/phpt')]
final class TestCaseTest extends FrameworkTestCase
{
public function testSortIdReturnsFilename(): void
{
$filename = realpath(__DIR__ . '/../../.. | {
"filepath": "tests/unit/Runner/Phpt/TestCaseTest.php",
"language": "php",
"file_size": 1111,
"cut_index": 515,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\DataProvider... |
return [
[
HookMethodCollection::defaultBeforeClass()->add(new HookMethod('someMethod', 0)),
['someMethod', 'setUpBeforeClass'],
],
[
HookMethodCollection::default | #[Group('test-runner/hook-methods')]
final class HookMethodCollectionTest extends TestCase
{
/**
* @return iterable<array{HookMethodCollection, list<string>}>
*/
public static function provider(): iterable
{ | {
"filepath": "tests/unit/Runner/HookMethod/HookMethodCollectionTest.php",
"language": "php",
"file_size": 2928,
"cut_index": 563,
"middle_length": 229
} |
tian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Baseline;
use function array_keys;
use function realpath;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Group;... | $this->assertCount(1, $issues);
$this->assertArrayHasKey($this->issue()->file(), $issues);
$lines = $issues[$this->issue()->file()];
$this->assertCount(1, $lines);
$this->assertArrayHasKey(10, $lines);
$line = | selineTest extends TestCase
{
public function testGroupsIssuesByFileAndLine(): void
{
$baseline = new Baseline;
$baseline->add($this->issue());
$issues = $baseline->groupedByFileAndLine();
| {
"filepath": "tests/unit/Runner/Baseline/BaselineTest.php",
"language": "php",
"file_size": 3328,
"cut_index": 614,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Baseline;
use function realpath;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\F... | ): void
{
$this->assertSame(
realpath(__DIR__ . '/../../../_files/baseline/FileWithIssues.php'),
$this->issue()->file(),
);
}
public function testHasLine(): void
{
$this->assertSame(10, $this | eDoesNotExistException::class)]
#[CoversClass(FileDoesNotHaveLineException::class)]
#[Small]
#[Group('test-runner')]
#[Group('test-runner/issue-baseline')]
final class IssueTest extends TestCase
{
public function testHasFile( | {
"filepath": "tests/unit/Runner/Baseline/IssueTest.php",
"language": "php",
"file_size": 2658,
"cut_index": 563,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Baseline;
use function realpath;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\F... | s->assertTrue($baseline->has($this->issue()));
$this->assertTrue($baseline->has($this->anotherIssue()));
$this->assertTrue($baseline->has($this->yetAnotherIssue()));
}
public function testCannotReadBaselineFromFileThatDoesNotExist( | seline')]
final class ReaderTest extends TestCase
{
public function testReadsBaselineFromFileWithValidXml(): void
{
$baseline = (new Reader)->read(__DIR__ . '/../../../_files/baseline/expected.xml');
$thi | {
"filepath": "tests/unit/Runner/Baseline/ReaderTest.php",
"language": "php",
"file_size": 2474,
"cut_index": 563,
"middle_length": 229
} |
tian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Baseline;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\Attributes\Group;
... | tring, string, string}>
*/
public static function dataGetRelativePath(): array
{
return [
[
'/usr/var/www',
'/usr/var/www/test.php',
'test.php',
],
[
| **
* @see Copied from https://github.com/phpstan/phpstan-src/blob/1.10.33/src/File/ParentDirectoryRelativePathHelper.php
*/
final class RelativePathCalculatorTest extends TestCase
{
/**
* @return non-empty-list<array{s | {
"filepath": "tests/unit/Runner/Baseline/RelativePathCalculatorTest.php",
"language": "php",
"file_size": 3817,
"cut_index": 614,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\Baseline;
use const DIRECTORY_SEPARATOR;
use function getcwd;
use function ltrim;
use functi... | string $target;
/**
* @return iterable<array{string}>
*/
public static function baselinePathProvider(): iterable
{
$absoluteBaselinePath = __DIR__ . '/../../../_files/baseline/expected.xml';
yield [$absoluteBaseline |
use PHPUnit\Framework\Attributes\Small;
use PHPUnit\Framework\TestCase;
#[CoversClass(Writer::class)]
#[Small]
#[Group('test-runner')]
#[Group('test-runner/issue-baseline')]
final class WriterTest extends TestCase
{
private | {
"filepath": "tests/unit/Runner/Baseline/WriterTest.php",
"language": "php",
"file_size": 2893,
"cut_index": 563,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\IssueTriggerResolver;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\At... | on testHasCalleeReturnsFalseWhenCalleeIsNull(): void
{
$resolution = new Resolution(null, null);
$this->assertFalse($resolution->hasCallee());
}
public function testCalleeReturnsSetValue(): void
{
$resolution = new | estCase
{
public function testHasCalleeReturnsTrueWhenCalleeIsSet(): void
{
$resolution = new Resolution('/path/to/callee.php', null);
$this->assertTrue($resolution->hasCallee());
}
public functi | {
"filepath": "tests/unit/Runner/IssueTriggerResolver/ResolutionTest.php",
"language": "php",
"file_size": 2528,
"cut_index": 563,
"middle_length": 229
} |
that was distributed with this source code.
*/
namespace PHPUnit\Runner\DeprecationCollector;
use function hrtime;
use PHPUnit\Event\Code\IssueTrigger\IssueTrigger;
use PHPUnit\Event\Code\TestDoxBuilder;
use PHPUnit\Event\Code\TestMethod;
use PHPUnit\Event\Telemetry\CpuTime;
use PHPUnit\Event\Telemetry\Duration;
use... | HPUnit\Framework\TestCase;
use PHPUnit\Metadata\MetadataCollection;
use PHPUnit\TestRunner\IssueFilter;
use PHPUnit\TextUI\Configuration\FilterDirectoryCollection;
use PHPUnit\TextUI\Configuration\FilterFileCollection;
use PHPUnit\TextUI\Configuration\Sour | shot;
use PHPUnit\Event\Test\DeprecationTriggered;
use PHPUnit\Event\TestData\TestDataCollection;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Group;
use PHPUnit\Framework\Attributes\Small;
use P | {
"filepath": "tests/unit/Runner/DeprecationCollector/InIsolationCollectorTest.php",
"language": "php",
"file_size": 5903,
"cut_index": 716,
"middle_length": 229
} |
that was distributed with this source code.
*/
namespace PHPUnit\Runner\ResultCache;
use const DIRECTORY_SEPARATOR;
use function file_put_contents;
use function is_file;
use function json_encode;
use function sys_get_temp_dir;
use function tempnam;
use function uniqid;
use function unlink;
use PHPUnit\Framework\Attr... | Clean = [];
protected function tearDown(): void
{
foreach ($this->filesToClean as $file) {
if (is_file($file)) {
@unlink($file);
}
}
}
public function testConstructorAppendsDefaultFi | ner\DirectoryDoesNotExistException;
#[CoversClass(DefaultResultCache::class)]
#[Small]
#[Group('test-runner')]
#[Group('test-runner/result-cache')]
final class DefaultResultCacheTest extends TestCase
{
private array $filesTo | {
"filepath": "tests/unit/Runner/ResultCache/DefaultResultCacheTest.php",
"language": "php",
"file_size": 6599,
"cut_index": 716,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\ResultCache;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\... | sAndMethodName(self::class, 'testOne');
$cache->setStatus($id, TestStatus::failure('failure'));
$this->assertTrue($cache->status($id)->isUnknown());
}
public function testStatusReturnsUnknown(): void
{
$cache = new Nu | r')]
#[Group('test-runner/result-cache')]
final class NullResultCacheTest extends TestCase
{
public function testSetStatusIsNoOp(): void
{
$cache = new NullResultCache;
$id = ResultCacheId::fromTestClas | {
"filepath": "tests/unit/Runner/ResultCache/NullResultCacheTest.php",
"language": "php",
"file_size": 2215,
"cut_index": 563,
"middle_length": 229
} |
tian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\ResultCache;
use const DIRECTORY_SEPARATOR;
use function sys_get_temp_dir;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\... | er/result-cache')]
final class ResultCacheHandlerTest extends AbstractEventTestCase
{
public function testMarkedIncompleteRecordsIncompleteStatus(): void
{
$cache = new DefaultResultCache(sys_get_temp_dir() . DIRECTORY_SEPARATOR . 'phpuni | Skipped;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Group;
use PHPUnit\Framework\Attributes\Small;
#[CoversClass(ResultCacheHandler::class)]
#[Small]
#[Group('test-runner')]
#[Group('test-runn | {
"filepath": "tests/unit/Runner/ResultCache/ResultCacheHandlerTest.php",
"language": "php",
"file_size": 3574,
"cut_index": 614,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\ResultCache;
use PHPUnit\Event\Code\Phpt;
use PHPUnit\Event\Code\TestDox;
use PHPUnit\Event\... | up('test-runner/result-cache')]
final class ResultCacheIdTest extends TestCase
{
/**
* @return iterable<array{string, ResultCacheId}>
*/
public static function provideResultCacheIds(): iterable
{
yield ['PHPUnit\Runner\ResultC | oup;
use PHPUnit\Framework\Attributes\Small;
use PHPUnit\Framework\Reorderable;
use PHPUnit\Framework\TestCase;
use PHPUnit\Metadata\MetadataCollection;
#[CoversClass(ResultCacheId::class)]
#[Small]
#[Group('test-runner')]
#[Gro | {
"filepath": "tests/unit/Runner/ResultCache/ResultCacheIdTest.php",
"language": "php",
"file_size": 2661,
"cut_index": 563,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Runner\ResultCache;
use const DIRECTORY_SEPARATOR;
use function sys_get_temp_dir;
use Exception;
us... | sideredRiskySubscriber::class)]
#[CoversClass(TestSkippedSubscriber::class)]
#[Small]
#[Group('test-runner')]
#[Group('test-runner/result-cache')]
final class SubscriberTest extends AbstractEventTestCase
{
public function testMarkedIncompleteSubscriber | HPUnit\Event\Test\Skipped;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Group;
use PHPUnit\Framework\Attributes\Small;
#[CoversClass(TestMarkedIncompleteSubscriber::class)]
#[CoversClass(TestCon | {
"filepath": "tests/unit/Runner/ResultCache/SubscriberTest.php",
"language": "php",
"file_size": 2966,
"cut_index": 563,
"middle_length": 229
} |
hot;
use PHPUnit\Event\Test\ConsideredRisky;
use PHPUnit\Event\Test\DeprecationTriggered;
use PHPUnit\Event\Test\Errored;
use PHPUnit\Event\Test\Failed;
use PHPUnit\Event\Test\Finished;
use PHPUnit\Event\Test\MarkedIncomplete;
use PHPUnit\Event\Test\NoticeTriggered;
use PHPUnit\Event\Test\Passed;
use PHPUnit\Event\Test... | it\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Group;
use PHPUnit\Framework\Attributes\Small;
use PHPUnit\Framework\TestCase;
use PHPUnit\Metadata\MetadataCollection;
use PHPUnit\TestFixture\InheritanceA;
use PHPUnit\TestFixture\Test | punitWarningTriggered;
use PHPUnit\Event\Test\PhpWarningTriggered;
use PHPUnit\Event\Test\Prepared;
use PHPUnit\Event\Test\Skipped;
use PHPUnit\Event\Test\WarningTriggered;
use PHPUnit\Event\TestData\TestDataCollection;
use PHPUn | {
"filepath": "tests/unit/Logging/TestDox/TestResult/TestResultCollectorTest.php",
"language": "php",
"file_size": 20998,
"cut_index": 1331,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use const PHP_EOL;
use PHPUnit\Event\AbstractEve... | Info();
$test = $this->testValueObject();
$message = 'message';
$event = new PhpunitErrorTriggered(
$telemetryInfo,
$test,
$message,
);
$this->assertSame($telemetr |
#[Group('event-system')]
#[Group('event-system/events')]
final class PhpunitErrorTriggeredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetry | {
"filepath": "tests/unit/Event/Events/Test/Issue/PhpunitErrorTriggeredTest.php",
"language": "php",
"file_size": 1276,
"cut_index": 524,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use const PHP_EOL;
use PHPUnit\Event\AbstractEventTestCase;
u... | $test = $this->testValueObject();
$message = 'message';
$ignoredByTest = false;
$event = new PhpunitWarningTriggered(
$telemetryInfo,
$test,
$message,
$ignoredBy | vent-system')]
#[Group('event-system/events')]
final class PhpunitWarningTriggeredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
| {
"filepath": "tests/unit/Event/Events/Test/Issue/PhpunitWarningTriggeredTest.php",
"language": "php",
"file_size": 1840,
"cut_index": 537,
"middle_length": 229
} |
ass)]
#[UsesClass(Before::class)]
#[UsesClass(BeforeClass::class)]
#[UsesClass(CoversClass::class)]
#[UsesClass(CoversFunction::class)]
#[UsesClass(CoversMethod::class)]
#[UsesClass(CoversNothing::class)]
#[UsesClass(DataProvider::class)]
#[UsesClass(DataProviderClosure::class)]
#[UsesClass(DependsOnClass::class)]
#[Us... | class)]
#[UsesClass(RequiresOperatingSystemFamily::class)]
#[UsesClass(RequiresPhp::class)]
#[UsesClass(RequiresPhpExtension::class)]
#[UsesClass(RequiresPhpunit::class)]
#[UsesClass(RequiresPhpunitExtension::class)]
#[UsesClass(RequiresEnvironmentVariable | class)]
#[UsesClass(PostCondition::class)]
#[UsesClass(PreCondition::class)]
#[UsesClass(PreserveGlobalState::class)]
#[UsesClass(RequiresFunction::class)]
#[UsesClass(RequiresMethod::class)]
#[UsesClass(RequiresOperatingSystem:: | {
"filepath": "tests/unit/Metadata/MetadataCollectionTest.php",
"language": "php",
"file_size": 23981,
"cut_index": 1331,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Metadata;
use PharIo\Version\VersionConstraintParser;
use PHPUnit\Framework\Attributes\CoversClass;... | quirement::class)]
#[CoversClass(ConstraintRequirement::class)]
#[CoversClass(Requirement::class)]
#[UsesClass(VersionComparisonOperator::class)]
#[Small]
#[Group('metadata')]
final class RequirementTest extends TestCase
{
/**
* @return non-empty- | k\TestCase;
use PHPUnit\Metadata\Version\ComparisonRequirement;
use PHPUnit\Metadata\Version\ConstraintRequirement;
use PHPUnit\Metadata\Version\Requirement;
use PHPUnit\Util\VersionComparisonOperator;
#[CoversClass(ComparisonRe | {
"filepath": "tests/unit/Metadata/Version/RequirementTest.php",
"language": "php",
"file_size": 3012,
"cut_index": 563,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | metryInfo();
$test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new PostConditionErrored(
$telemet | Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class PostConditionErroredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->tele | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/PostConditionErroredTest.php",
"language": "php",
"file_size": 1987,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use Exception;
use PHPUnit\Event\AbstractEventTestCase;
use P... | lemetryInfo();
$test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$throwable = Code\ThrowableBuilder::from(new Exception('message'));
$event = new AfterTestMethodFailed(
$tele | [Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class AfterTestMethodFailedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->te | {
"filepath": "tests/unit/Event/Events/Test/HookMethod/AfterTestMethodFailedTest.php",
"language": "php",
"file_size": 1986,
"cut_index": 537,
"middle_length": 229
} |
s=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Co... | $test = $this->testValueObject();
$calledMethod = $this->calledMethod();
$event = new PostConditionCalled(
$telemetryInfo,
$test,
$calledMethod,
);
$this->assertSame($telem | event-system')]
#[Group('event-system/events')]
final class PostConditionCalledTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
| {
"filepath": "tests/unit/Event/Events/Test/HookMethod/PostConditionCalledTest.php",
"language": "php",
"file_size": 1649,
"cut_index": 537,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use const PHP_EOL;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Framework\Attri... | ct();
$message = 'message';
$file = 'file';
$line = 1;
$suppressed = false;
$event = new ErrorTriggered(
$telemetryInfo,
$test,
$message,
$f | m/events')]
final class ErrorTriggeredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test = $this->testValueObje | {
"filepath": "tests/unit/Event/Events/Test/Issue/ErrorTriggeredTest.php",
"language": "php",
"file_size": 2039,
"cut_index": 563,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use const PHP_EOL;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Framework\Attri... | s->testValueObject();
$message = 'message';
$file = 'file';
$line = 1;
$suppressed = false;
$ignoredByBaseline = false;
$event = new PhpNoticeTriggered(
| ystem/events')]
final class PhpNoticeTriggeredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test = $thi | {
"filepath": "tests/unit/Event/Events/Test/Issue/PhpNoticeTriggeredTest.php",
"language": "php",
"file_size": 2746,
"cut_index": 563,
"middle_length": 229
} |
that was distributed with this source code.
*/
namespace PHPUnit\Metadata\Parser;
use PHPUnit\Framework\Attributes\After;
use PHPUnit\Framework\Attributes\AfterClass;
use PHPUnit\Framework\Attributes\AllowMockObjectsWithoutExpectations;
use PHPUnit\Framework\Attributes\BackupGlobals;
use PHPUnit\Framework\Attributes... | oversNamespace;
use PHPUnit\Framework\Attributes\CoversNothing;
use PHPUnit\Framework\Attributes\CoversTrait;
use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\Attributes\DataProviderExternal;
use PHPUnit\Framework\Attributes\Depends;
us | oversClassesThatExtendClass;
use PHPUnit\Framework\Attributes\CoversClassesThatImplementInterface;
use PHPUnit\Framework\Attributes\CoversFunction;
use PHPUnit\Framework\Attributes\CoversMethod;
use PHPUnit\Framework\Attributes\C | {
"filepath": "tests/unit/Metadata/Parser/AttributeParserTest.php",
"language": "php",
"file_size": 6846,
"cut_index": 716,
"middle_length": 229
} |
that was distributed with this source code.
*/
namespace PHPUnit\Metadata\Api;
use function array_shift;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\Attributes\Group;
use PHPUnit\Framework\Attributes\Small;
use PHPUnit\Framework\Attributes\TestDo... | SebastianBergmann\CodeCoverage\Test\Target\ClassesThatImplementInterface;
use SebastianBergmann\CodeCoverage\Test\Target\Function_;
use SebastianBergmann\CodeCoverage\Test\Target\Method;
use SebastianBergmann\CodeCoverage\Test\Target\Namespace_;
use Sebast | PHPUnit\TestFixture\Metadata\Attribute\UsesTest;
use PHPUnit\TestFixture\NoCoverageAttributesTest;
use SebastianBergmann\CodeCoverage\Test\Target\Class_;
use SebastianBergmann\CodeCoverage\Test\Target\ClassesThatExtendClass;
use | {
"filepath": "tests/unit/Metadata/Api/CodeCoverageTest.php",
"language": "php",
"file_size": 5900,
"cut_index": 716,
"middle_length": 229
} |
that was distributed with this source code.
*/
namespace PHPUnit\Metadata\Api;
use function array_keys;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Group;
use PHPUnit\Framework\Attributes\Small;
use PHPUnit\Framework\TestCase;
use PHPUnit\Runner\HookMethod;
use PHPUnit\Runner\HookM... | sertEquals(
[
'beforeClass' => HookMethodCollection::defaultBeforeClass(),
'before' => HookMethodCollection::defaultBefore(),
'preCondition' => HookMethodCollection::defaultPreCondition( | (HookMethods::class)]
#[Small]
#[Group('metadata')]
#[Group('metadata/api')]
final class HookMethodsTest extends TestCase
{
public function testReturnsDefaultHookMethodsForClassThatDoesNotExist(): void
{
$this->as | {
"filepath": "tests/unit/Metadata/Api/HookMethodsTest.php",
"language": "php",
"file_size": 5501,
"cut_index": 716,
"middle_length": 229
} |
tian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Logging\TestDox;
use PHPUnit\Event\Code\TestDoxBuilder;
use PHPUnit\Event\Code\TestMethod;
use PHPUnit\Event\TestData\TestDataCollection;
use PHPUnit\... | no_test_results(): void
{
$this->assertStringEqualsFile(
__DIR__ . '/expectations/html/empty.html',
(new HtmlRenderer)->render([]),
);
}
public function test_Successful_test_method_is_marked_as_success() | se PHPUnit\Metadata\MetadataCollection;
#[CoversClass(HtmlRenderer::class)]
#[Group('testdox')]
#[Small]
final class HtmlRendererTest extends TestCase
{
public function test_Empty_input_renders_a_complete_HTML_document_with_ | {
"filepath": "tests/unit/Logging/TestDox/HtmlRendererTest.php",
"language": "php",
"file_size": 4191,
"cut_index": 614,
"middle_length": 229
} |
tian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Logging\TestDox;
use PHPUnit\Event\Code\TestDoxBuilder;
use PHPUnit\Event\Code\TestMethod;
use PHPUnit\Event\TestData\TestDataCollection;
use PHPUnit\... | : void
{
$this->assertStringEqualsFile(
__DIR__ . '/expectations/plain-text/empty.txt',
(new PlainTextRenderer)->render([]),
);
}
public function test_Successful_test_method_is_marked_with_x(): void
| se PHPUnit\Metadata\MetadataCollection;
#[CoversClass(PlainTextRenderer::class)]
#[Group('testdox')]
#[Small]
final class PlainTextRendererTest extends TestCase
{
public function test_Empty_input_renders_to_an_empty_string() | {
"filepath": "tests/unit/Logging/TestDox/PlainTextRendererTest.php",
"language": "php",
"file_size": 4551,
"cut_index": 614,
"middle_length": 229
} |
tian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Logging\TestDox;
use function iterator_to_array;
use PHPUnit\Event\Code\TestDoxBuilder;
use PHPUnit\Event\Code\TestMethod;
use PHPUnit\Event\TestData\... | nTest extends TestCase
{
public function test_An_empty_collection_can_be_created(): void
{
$collection = TestResultCollection::fromArray([]);
$this->assertSame([], $collection->asArray());
$this->assertSame([], iterator_to_ | amework\TestStatus\TestStatus;
use PHPUnit\Metadata\MetadataCollection;
#[CoversClass(TestResultCollection::class)]
#[CoversClass(TestResultCollectionIterator::class)]
#[Group('testdox')]
#[Small]
final class TestResultCollectio | {
"filepath": "tests/unit/Logging/TestDox/TestResult/TestResultCollectionTest.php",
"language": "php",
"file_size": 3466,
"cut_index": 614,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use const PHP_EOL;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Framework\Attri... | his->testValueObject();
$message = 'message';
$file = 'file';
$line = 1;
$suppressed = false;
$ignoredByBaseline = false;
$event = new PhpWarningTriggered(
| system/events')]
final class PhpWarningTriggeredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test = $t | {
"filepath": "tests/unit/Event/Events/Test/Issue/PhpWarningTriggeredTest.php",
"language": "php",
"file_size": 2754,
"cut_index": 563,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use const PHP_EOL;
use PHPUnit\Event\AbstractEve... | ryInfo();
$test = $this->testValueObject();
$message = 'message';
$event = new PhpunitNoticeTriggered(
$telemetryInfo,
$test,
$message,
);
$this->assertSame($telem | ]
#[Group('event-system')]
#[Group('event-system/events')]
final class PhpunitNoticeTriggeredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemet | {
"filepath": "tests/unit/Event/Events/Test/Issue/PhpunitNoticeTriggeredTest.php",
"language": "php",
"file_size": 1280,
"cut_index": 524,
"middle_length": 229
} |
e(strict_types=1);
/*
* This file is part of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Application;
use PHPUnit\Event\AbstractEventTestCase;
... | );
$runtime = new Runtime;
$event = new Started(
$telemetryInfo,
$runtime,
);
$this->assertSame($telemetryInfo, $event->telemetryInfo());
$this->assertSame($runtime, $event->runtime()) |
#[Small]
#[Group('event-system')]
#[Group('event-system/events')]
final class StartedTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo( | {
"filepath": "tests/unit/Event/Events/Application/StartedTest.php",
"language": "php",
"file_size": 1299,
"cut_index": 524,
"middle_length": 229
} |
art of PHPUnit.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use const PHP_EOL;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Framework\Attri... | tValueObject();
$message = 'message';
$file = 'file';
$line = 1;
$suppressed = false;
$ignoredByBaseline = false;
$event = new NoticeTriggered(
$telemet | em/events')]
final class NoticeTriggeredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test = $this->tes | {
"filepath": "tests/unit/Event/Events/Test/Issue/NoticeTriggeredTest.php",
"language": "php",
"file_size": 2719,
"cut_index": 563,
"middle_length": 229
} |
tian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Event\Test;
use const PHP_EOL;
use PHPUnit\Event\AbstractEventTestCase;
use PHPUnit\Event\Code\IssueTrigger\IssueTrigger;
use PHPUnit\Framework\Attrib... | = $this->testValueObject();
$message = 'message';
$file = 'file';
$line = 1;
$suppressed = false;
$ignoredByBaseline = false;
$ignoredByTest = false;
| nt-system/events')]
final class PhpDeprecationTriggeredTest extends AbstractEventTestCase
{
public function testConstructorSetsValues(): void
{
$telemetryInfo = $this->telemetryInfo();
$test | {
"filepath": "tests/unit/Event/Events/Test/Issue/PhpDeprecationTriggeredTest.php",
"language": "php",
"file_size": 4076,
"cut_index": 614,
"middle_length": 229
} |
that was distributed with this source code.
*/
namespace PHPUnit\Metadata\Api;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Group;
use PHPUnit\Framework\Attributes\Small;
use PHPUnit\Framework\InvalidDataProviderException;
use PHPUnit\Framework\TestCase;
use PHPUnit\TestFixture\Dupl... | roviders are being merged.
*/
public function testMultipleDataProviders(): void
{
$dataSets = $this->getRawDataFromProvidedData(
(new DataProvider)->providedData(MultipleDataProviderTest::class, 'testOne'),
);
| e PHPUnit\TestFixture\VariousIterableDataProviderTest;
#[CoversClass(DataProvider::class)]
#[Small]
#[Group('metadata')]
#[Group('metadata/api')]
final class DataProviderTest extends TestCase
{
/**
* Check if all data p | {
"filepath": "tests/unit/Metadata/Api/DataProviderTest.php",
"language": "php",
"file_size": 6815,
"cut_index": 716,
"middle_length": 229
} |
that was distributed with this source code.
*/
namespace PHPUnit\Metadata\Api;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\Attributes\Group;
use PHPUnit\Framework\Attributes\Small;
use PHPUnit\Framework\TestCase;
use PHPUnit\TestFixture\Requireme... | 'Function testFunc() is required.',
]],
['testTen', [
'PHP extension testExt is required.',
]],
['testAlwaysSkip', [
'PHPUnit >= 1111111.0.0 is required.',
| on-empty-list<array{string, list<string>}>
*/
public static function missingRequirementsProvider(): array
{
return [
['testOne', []],
['testNine', [
| {
"filepath": "tests/unit/Metadata/Api/RequirementsTest.php",
"language": "php",
"file_size": 6276,
"cut_index": 716,
"middle_length": 229
} |
that was distributed with this source code.
*/
namespace PHPUnit\Logging\TestDox;
use DateTimeImmutable;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\Attributes\Group;
use PHPUnit\Framework\Attributes\Small;
use PHPUnit\Framework\TestCase;
use PHP... | unction classNameProvider(): array
{
return [
[
'Foo',
'FooTest',
],
[
'Test Foo',
'TestFoo',
],
[
'Test | CoversClass(NamePrettifier::class)]
#[Group('testdox')]
#[Small]
final class NamePrettifierTest extends TestCase
{
/**
* @return non-empty-list<array{0: non-empty-string, 1: non-empty-string}>
*/
public static f | {
"filepath": "tests/unit/Logging/TestDox/NamePrettifierTest.php",
"language": "php",
"file_size": 6867,
"cut_index": 716,
"middle_length": 229
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.