Simplified transactional URL shortening

This commit is contained in:
Alejandro Celaya
2020-11-06 20:05:57 +01:00
parent 00255b04eb
commit 97f89bcede
11 changed files with 35 additions and 55 deletions

View File

@@ -72,7 +72,7 @@ class SingleStepCreateShortUrlActionTest extends TestCase
'longUrl' => 'http://foobar.com',
]);
$findApiKey = $this->apiKeyService->check('abc123')->willReturn(true);
$generateShortCode = $this->urlShortener->urlToShortCode(
$generateShortCode = $this->urlShortener->shorten(
Argument::that(function (string $argument): string {
Assert::assertEquals('http://foobar.com', $argument);
return $argument;