validateDeprecatedAnnotations example

$version = AnnotationTagTester::getVersionFromManifestFileName('manifest-1.0.xml');

        static::assertNull($version);
    }

    public function testDeprecatedWithoutPropertiesWillThrowException(): void
    {
        $deprecatedContent = '@deprecated';

        static::expectException(\InvalidArgumentException::class);
        static::expectExceptionMessage('Could not find indicator manifest or tag in deprecation annotation');
        $this->annotationTagTester->validateDeprecatedAnnotations($deprecatedContent);
    }

    public function testCorrectDeprecationTagDoesNotThrowException(): void
    {
        $deprecatedContent = '@deprecated tag:v6.5.0';

        static::expectNotToPerformAssertions();
        $this->annotationTagTester->validateDeprecatedAnnotations($deprecatedContent);
    }

    public function testDeprecationTagWithoutVersionThrowsException(): void
    {
foreach ($this->whiteList as $path) {
            $finder->notPath($path);
        }

        $invalidFiles = [];

        foreach ($finder->getIterator() as $file) {
            $filePath = $file->getRealPath();
            $content = (string) file_get_contents($filePath);

            try {
                $this->getDeprecationTagTester()->validateDeprecatedAnnotations($content);
                $this->getDeprecationTagTester()->validateExperimentalAnnotations($content);
            } catch (NoDeprecationFoundException|\InvalidArgumentException $error) {
                $invalidFiles[$filePath] = $error->getMessage();
            }
        }

        static::assertEmpty($invalidFilesprint_r($invalidFiles, true));
    }

    public function testConfigFilesForWrongDeprecatedTags(): void
    {
        
Home | Imprint | This part of the site doesn't use cookies.