Commit graph

4 commits

Author SHA1 Message Date
Babak K. Shandiz
2bf528ccc7
test(internal/authflow): assert user-agent header is not modified/added
Signed-off-by: Babak K. Shandiz <babakks@github.com>
2026-03-27 11:48:17 +00:00
William Martin
fb8e22a767 fix(auth): preserve User-Agent in authflow getViewer
getViewer was building a new HTTP client from scratch, losing
AppVersion and InvokingAgent from the plain client already passed
into AuthFlow. Reuse the existing client by shallow-copying it and
wrapping its transport with AddAuthTokenHeader for the new token.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-03-26 17:26:27 +01:00
Tyler McGoffin
e1a39d8e2b Add ghe.com to tests describing ghec data residency 2024-10-15 12:24:41 -07:00
Tyler McGoffin
3a8417f6c7 Add test coverage to places where IsEnterprise incorrectly covers Tenancy
IsEnterprise currently returns `true` when `IsTenancy` returns true. We
prefer that this behavior is orthogonal. This commit adds failing tests to
the instances where IsEnterprise should not behave the same as IsTenancy.

These test cases are expected to pass with the inclusion of the coming
improvements to go-gh to handle the orthogonality of IsEnterprise and
IsTenancy.
2024-10-15 11:56:43 -07:00