feat: enable type-aware no-base-to-string rule, fix 56 violations (#22750)

This commit is contained in:
Kit Langton
2026-04-15 23:50:47 -04:00
committed by GitHub
parent c802695ee9
commit 8aa0f9fe95
26 changed files with 87 additions and 55 deletions

View File

@@ -1801,7 +1801,7 @@ test("project config overrides remote well-known config", async () => {
const originalFetch = globalThis.fetch
let fetchedUrl: string | undefined
globalThis.fetch = mock((url: string | URL | Request) => {
const urlStr = url.toString()
const urlStr = url instanceof Request ? url.url : url instanceof URL ? url.href : url
if (urlStr.includes(".well-known/opencode")) {
fetchedUrl = urlStr
return Promise.resolve(
@@ -1858,7 +1858,7 @@ test("wellknown URL with trailing slash is normalized", async () => {
const originalFetch = globalThis.fetch
let fetchedUrl: string | undefined
globalThis.fetch = mock((url: string | URL | Request) => {
const urlStr = url.toString()
const urlStr = url instanceof Request ? url.url : url instanceof URL ? url.href : url
if (urlStr.includes(".well-known/opencode")) {
fetchedUrl = urlStr
return Promise.resolve(