diff options
| author | Joe Mou <dev@mou.fo> | 2026-02-11 01:56:37 -0500 |
|---|---|---|
| committer | Joe Mou <dev@mou.fo> | 2026-02-11 01:56:49 -0500 |
| commit | 934b2c39537d6718375170a029fc1d1df01024c5 (patch) | |
| tree | 0e105a684b16554a19d1ba40b7e977e0c18a94b8 /src/scraper.test.ts | |
| parent | b75d4cfb610b8792e6f1236b613f554d1ac5b78d (diff) | |
Add GitHub releases support
Scrapes releases page HTML to display version tags, publish dates, and changelog content.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Diffstat (limited to 'src/scraper.test.ts')
| -rw-r--r-- | src/scraper.test.ts | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/scraper.test.ts b/src/scraper.test.ts index 7cafd9c..8c11317 100644 --- a/src/scraper.test.ts +++ b/src/scraper.test.ts @@ -4,6 +4,7 @@ import { getGitHubBlob, getGitHubCommits, getGitHubIssues, + getGitHubReleases, getGitHubRepo, getGitHubTree, GitHubHTTPError, @@ -159,6 +160,19 @@ describe("GitHub scraper", () => { assert.ok(data.commitGroups.length > 0); }); + + it("should fetch releases", async () => { + const data = await getGitHubReleases("actions", "deploy-pages"); + + assert.strictEqual(data.repo.owner, "actions"); + assert.strictEqual(data.repo.name, "deploy-pages"); + + assert.ok(data.releases.length > 0); + const firstRelease = data.releases[0]; + assert.ok(firstRelease.tagName.length > 0); + assert.ok(firstRelease.title.match(/^v\d/)); + assert.ok(firstRelease.publishedAt.length > 0); + }); }); describe("rich file types", () => { |
