ForgejoKit/Tests/ForgejoKitTests
Voislav Vasiljevski 3967a1ba79 feat: add Forgejo Actions runs API (#1)
New model:
  - WorkflowRun — mirrors Forgejo's ActionRun schema (id, title, status,
    event, indexInRepo, commitSha, prettyRef, workflowId, created, updated,
    started, stopped, durationNanos, htmlUrl, triggerUser, repository).

New service:
  - WorkflowService
      - fetchRuns(owner:repo:status:event:ref:workflowId:runNumber:headSha:page:limit:)
        backed by GET /repos/{owner}/{repo}/actions/runs.
      - fetchRun(owner:repo:runId:) backed by
        GET /repos/{owner}/{repo}/actions/runs/{run_id}.

Experimental:
  - fetchRunView(owner:repo:runIndex:jobIndex:logCursors:) backed by
    Forgejo's web-UI route POST
    /{owner}/{repo}/actions/runs/{runIndex}/jobs/{jobIndex}/attempt/{N}.
    This is not part of /api/v1 and may change between Forgejo releases;
    it lets clients render jobs, steps, and step logs (via WorkflowRunView,
    WorkflowRunViewJob, WorkflowRunViewStep, WorkflowLogCursor types).
  - ForgejoClient.discoverRedirectLocation(url:) helper that resolves
    Forgejo's RedirectToLatestAttempt without consuming the redirect
    target — used to find the latest attempt number before POSTing.

Co-authored-by: Voislav Vasiljevski <voislav@voioo.cz>
Reviewed-on: https://codeberg.org/secana/ForgejoKit/pulls/1
Reviewed-by: secana <secana@noreply.codeberg.org>
2026-05-07 16:42:16 +02:00
..
AdminServiceTests.swift feat: add new models and services 2026-03-11 21:57:40 +01:00
DateDecodingTests.swift feat: initial commit 2026-02-28 20:25:57 +01:00
DiffParserTests.swift feat: initial commit 2026-02-28 20:25:57 +01:00
FileContentTests.swift feat: initial commit 2026-02-28 20:25:57 +01:00
ModelDecodingTests.swift feat: add Forgejo Actions runs API (#1) 2026-05-07 16:42:16 +02:00
NormalizeServerURLTests.swift feat: initial commit 2026-02-28 20:25:57 +01:00
NotificationTests.swift feat: initial commit 2026-02-28 20:25:57 +01:00
RepositoryServiceURLTests.swift feat: add new models and services 2026-03-11 21:57:40 +01:00
URLSessionManagerTests.swift feat: initial commit 2026-02-28 20:25:57 +01:00
UserServiceTests.swift feat: add new models and services 2026-03-11 21:57:40 +01:00
WorkflowServiceURLTests.swift feat: add Forgejo Actions runs API (#1) 2026-05-07 16:42:16 +02:00