Skip to content

Commit 6f0aa64

Browse files
committed
tests: add new repo fields to tests
1 parent b4083a1 commit 6f0aa64

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

test/github_link_test.ml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ let mk_repo ?(scheme = "https") prefix prefix_api : repository =
1111
url = sprintf "%s://%s/ahrefs/monorepo" scheme prefix;
1212
commits_url = sprintf "%s://%s/repos/ahrefs/monorepo/commits{/sha}" scheme prefix_api;
1313
contents_url = sprintf "%s://%s/repos/ahrefs/monorepo/contents/{+path}" scheme prefix_api;
14+
pulls_url = sprintf "%s://%s/repos/ahrefs/monorepo/pulls{/number}" scheme prefix_api;
15+
issues_url = sprintf "%s://%s/repos/ahrefs/monorepo/issues{/number}" scheme prefix_api;
1416
}
1517

1618
let enterprise_repo1 = mk_repo "example.org" "example.org/api/v3"

test/test.ml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,9 @@ let process ~(ctx : Context.t) (kind, path, state_path) =
4242

4343
let () =
4444
let payloads = get_mock_payloads () in
45-
let repo : Github_t.repository = { name = ""; full_name = ""; url = ""; commits_url = ""; contents_url = "" } in
45+
let repo : Github_t.repository =
46+
{ name = ""; full_name = ""; url = ""; commits_url = ""; contents_url = ""; pulls_url = ""; issues_url = "" }
47+
in
4648
let ctx = Context.make ~state_filepath:"state.json" () in
4749
Lwt_main.run
4850
( match%lwt Api_local.Github.get_config ~ctx ~repo with

0 commit comments

Comments
 (0)