/** * @depends testAdd * * @return void */ public function testDisableAndEnable() { $this->util->setMenu('/queue/simple'); $id = $this->util->add(array('name' => TEST_QUEUE_NAME, 'disabled' => 'no', 'target' => '0.0.0.0/0')); $printRequest = new Request('/queue/simple/print', Query::where('.id', $id)); $this->assertSame('false', $this->client->sendSync($printRequest)->getProperty('disabled')); $this->util->disable($id); $this->assertSame('true', $this->client->sendSync($printRequest)->getProperty('disabled')); $this->util->enable($id); $this->assertSame('false', $this->client->sendSync($printRequest)->getProperty('disabled')); $removeRequest = new Request('/queue/simple/remove'); $removeRequest->setArgument('numbers', $id); $this->client->sendSync($removeRequest); }