unregisterType() public method

See also: elgg_unregister_widget_type
Since: 1.9.0
public unregisterType ( string $id ) : boolean
$id string
return boolean
Example #1
0
 /**
  * @depends testRegistrationParametersPreserveNameDescription
  * @param \Elgg\WidgetsService $service
  */
 public function testCanUnregisterType($service)
 {
     $this->assertTrue($service->unregisterType('widget_type'));
     $this->assertTrue($service->unregisterType('widget_type_con'));
     $this->assertTrue($service->unregisterType('widget_type_mul'));
     $this->assertTrue($service->unregisterType('widget_type_con_mul'));
     $this->assertFalse($service->unregisterType('widget_not_registered'));
     $this->assertFalse($service->validateType('widget_type'));
     $this->assertFalse($service->validateType('widget_type_con'));
     $this->assertFalse($service->validateType('widget_type_mul'));
     $this->assertFalse($service->validateType('not_registered_widget'));
 }