Skip to content

Commit

Permalink
Codecoverage for prepareUri (#53)
Browse files Browse the repository at this point in the history
  • Loading branch information
ruebot authored and whikloj committed Jul 26, 2016
1 parent 416f5a5 commit a0b06b6
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions test/CreateTransactionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,12 @@ class CreateTransactionTest extends \PHPUnit_Framework_TestCase

/**
* @covers Islandora\Chullo\Chullo::createTransaction
* @covers Islandora\Chullo\Chullo::getBaseUri
* @covers Islandora\Chullo\FedoraApi::createTransaction
* @covers Islandora\Chullo\FedoraApi::prepareUri
* @covers Islandora\Chullo\FedoraApi::getBaseUri
* @covers Islandora\Chullo\FedoraApi::createTransaction
* @covers Islandora\Chullo\FedoraApi::generateTransactionUri
* @uses GuzzleHttp\Client
*/
public function testReturnsIdOn201()
Expand All @@ -28,12 +33,19 @@ public function testReturnsIdOn201()
$api = new FedoraApi($guzzle);
$client = new Chullo($api);

$this->assertEquals($client->getBaseUri(), 'http://localhost:8080/fcrepo/rest');

$result = $client->createTransaction();
$this->assertSame($result, "tx:abc-123");
}
/**
* @covers Islandora\Chullo\Chullo::createTransaction
* @covers Islandora\Chullo\Chullo::getBaseUri
* @covers Islandora\Chullo\FedoraApi::createTransaction
* @covers Islandora\Chullo\FedoraApi::prepareUri
* @covers Islandora\Chullo\FedoraApi::getBaseUri
* @covers Islandora\Chullo\FedoraApi::createTransaction
* @covers Islandora\Chullo\FedoraApi::generateTransactionUri
* @uses GuzzleHttp\Client
*/
public function testReturnsNullOtherwise()
Expand Down

0 comments on commit a0b06b6

Please sign in to comment.