Kraken\_Unit\Util\Factory\_Partial\FactoryPartial::testApiRemove_RemovesFactoryMethod_ForExistingMethod PHP Метод

testApiRemove_RemovesFactoryMethod_ForExistingMethod() публичный Метод

    public function testApiRemove_RemovesFactoryMethod_ForExistingMethod()
    {
        $test = $this->getTest();
        $factory = $this->createFactory();
        $key = 'KEY';
        $callable = function () {
        };
        $factory->define($key, $callable);
        $test->assertTrue($factory->hasDefinition($key));
        $factory->remove($key);
        $test->assertFalse($factory->hasDefinition($key));
    }