Exemplo n.º 1
0
 function testGetRoleAllocation()
 {
     $randomFile = APIDocumentHelper::createRandomFile();
     $this->assertTrue(is_file($randomFile));
     $document = $this->root->add_document('testtitle', 'testname.txt', 'Default', $randomFile);
     @unlink($randomFile);
     $this->assertNotError($document);
     if (PEAR::isError($document)) {
         return;
     }
     $response = $this->ktapi->get_role_allocation_for_document($document->get_documentid());
     $this->assertEqual($response['status_code'], 0);
     $document->delete('Testing');
     $document->expunge();
 }