private function givenOnlyPropertiesWithTheAnnotation_ShouldBeInjected($annotation) { $this->provider = new DefaultProvider($this->fix->factory); $this->fix->factory->setProvider('StdClass', $this->provider); $this->provider->setPropertyFilter(function (\ReflectionProperty $property) use($annotation) { return strpos($property->getDocComment(), $annotation) !== false; }); }