createFromName() public static method

Cannot instantiate this way, use ReflectionObject::createFromInstance
public static createFromName ( $className )
 public function testCreateFromNameThrowsException()
 {
     $this->expectException(\LogicException::class);
     ReflectionObject::createFromName('foo');
 }