diff --git a/src/Api/Suborganizations/Packages.php b/src/Api/Suborganizations/Packages.php index 0289130..b2e02d9 100644 --- a/src/Api/Suborganizations/Packages.php +++ b/src/Api/Suborganizations/Packages.php @@ -27,7 +27,7 @@ public function all($suborganizationName, array $filters = []) public function show($suborganizationName, $packageIdOrName) { - return $this->get(sprintf('/suborganizations/%s/packages/%s', $suborganizationName, $packageIdOrName)); + return $this->get(sprintf('/suborganizations/%s/packages/%s/', $suborganizationName, $packageIdOrName)); } public function createVcsPackage($suborganizationName, $url, $credentialId = null, $type = 'vcs', $defaultSuborganizationAccess = null) diff --git a/src/Api/Subrepositories/Packages.php b/src/Api/Subrepositories/Packages.php index 7f0a0b1..6faa4bf 100644 --- a/src/Api/Subrepositories/Packages.php +++ b/src/Api/Subrepositories/Packages.php @@ -30,7 +30,7 @@ public function all($subrepositoryName, array $filters = []) public function show($subrepositoryName, $packageIdOrName) { - return $this->get(sprintf('/subrepositories/%s/packages/%s', $subrepositoryName, $packageIdOrName)); + return $this->get(sprintf('/subrepositories/%s/packages/%s/', $subrepositoryName, $packageIdOrName)); } public function createVcsPackage($subrepositoryName, $url, $credentialId = null, $type = 'vcs', $defaultSubrepositoryAccess = null) diff --git a/tests/Api/Projects/PackagesTest.php b/tests/Api/Projects/PackagesTest.php index cdbf65e..4730d6d 100644 --- a/tests/Api/Projects/PackagesTest.php +++ b/tests/Api/Projects/PackagesTest.php @@ -88,7 +88,7 @@ public function testShow() $api = $this->getApiMock(); $api->expects($this->once()) ->method('get') - ->with($this->equalTo('/subrepositories/project/packages/acme-website/package')) + ->with($this->equalTo('/subrepositories/project/packages/acme-website/package/')) ->willReturn($expected); $this->assertSame($expected, $api->show($projectName, 'acme-website/package')); diff --git a/tests/Api/Suborganizations/PackagesTest.php b/tests/Api/Suborganizations/PackagesTest.php index 0753df0..06595a3 100644 --- a/tests/Api/Suborganizations/PackagesTest.php +++ b/tests/Api/Suborganizations/PackagesTest.php @@ -88,7 +88,7 @@ public function testShow() $api = $this->getApiMock(); $api->expects($this->once()) ->method('get') - ->with($this->equalTo('/suborganizations/suborganization/packages/acme-website/package')) + ->with($this->equalTo('/suborganizations/suborganization/packages/acme-website/package/')) ->willReturn($expected); $this->assertSame($expected, $api->show($suborganizationName, 'acme-website/package')); diff --git a/tests/Api/Subrepositories/PackagesTest.php b/tests/Api/Subrepositories/PackagesTest.php index 3078807..e1ca277 100644 --- a/tests/Api/Subrepositories/PackagesTest.php +++ b/tests/Api/Subrepositories/PackagesTest.php @@ -88,7 +88,7 @@ public function testShow() $api = $this->getApiMock(); $api->expects($this->once()) ->method('get') - ->with($this->equalTo('/subrepositories/subrepository/packages/acme-website/package')) + ->with($this->equalTo('/subrepositories/subrepository/packages/acme-website/package/')) ->willReturn($expected); $this->assertSame($expected, $api->show($subrepositoryName, 'acme-website/package'));