Save to database #13

Merged
haylan merged 42 commits from save-to-database into main 2026-07-12 21:51:57 +00:00
Showing only changes of commit c89b4e9212 - Show all commits
@@ -78,7 +78,8 @@ final class GiteaProviderTest extends TestCase
['timestamp' => $now, 'contributions' => 5], ['timestamp' => $now, 'contributions' => 5],
])); ]));
$result = $this->makeProvider(client: $client)->fetch(); $provider = $this->makeProvider(client: $client);
$result = $provider->resolveFetch($provider->startFetch());
$this->assertSame(5, $result[date('Y-m-d', $now)]); $this->assertSame(5, $result[date('Y-m-d', $now)]);
} }
@@ -93,7 +94,8 @@ final class GiteaProviderTest extends TestCase
['timestamp' => $old, 'contributions' => 3], ['timestamp' => $old, 'contributions' => 3],
])); ]));
$result = $this->makeProvider(client: $client)->fetch(); $provider = $this->makeProvider(client: $client);
$result = $provider->resolveFetch($provider->startFetch());
$this->assertSame([], $result); $this->assertSame([], $result);
} }
@@ -104,7 +106,8 @@ final class GiteaProviderTest extends TestCase
$client = $this->createStub(HttpClientInterface::class); $client = $this->createStub(HttpClientInterface::class);
$client->method('request')->willReturn($this->stubResponse([])); $client->method('request')->willReturn($this->stubResponse([]));
$result = $this->makeProvider(client: $client)->fetch(); $provider = $this->makeProvider(client: $client);
$result = $provider->resolveFetch($provider->startFetch());
$this->assertSame([], $result); $this->assertSame([], $result);
} }