@@ -2,7 +2,7 @@
|
||||
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
|
||||
import { TwitterClient } from '../src/lib/twitter-client.js';
|
||||
import { type TwitterClientPrivate, validCookies } from './twitter-client-fixtures.js';
|
||||
import { type TwitterClientPrivate, testRelayBaseUrl } from './twitter-client-fixtures.js';
|
||||
|
||||
const originalFetch = global.fetch;
|
||||
|
||||
@@ -69,7 +69,7 @@ describe('TwitterClient lists timeline', () => {
|
||||
}),
|
||||
});
|
||||
|
||||
const client = new TwitterClient({ cookies: validCookies });
|
||||
const client = new TwitterClient({ relayBaseUrl: testRelayBaseUrl });
|
||||
const clientPrivate = client as unknown as TwitterClientPrivate;
|
||||
clientPrivate.getListTimelineQueryIds = async () => ['test'];
|
||||
|
||||
@@ -98,7 +98,7 @@ describe('TwitterClient lists timeline', () => {
|
||||
}),
|
||||
});
|
||||
|
||||
const client = new TwitterClient({ cookies: validCookies });
|
||||
const client = new TwitterClient({ relayBaseUrl: testRelayBaseUrl });
|
||||
const clientPrivate = client as unknown as TwitterClientPrivate;
|
||||
clientPrivate.getListTimelineQueryIds = async () => ['test'];
|
||||
|
||||
@@ -115,7 +115,7 @@ describe('TwitterClient lists timeline', () => {
|
||||
text: async () => 'Forbidden',
|
||||
});
|
||||
|
||||
const client = new TwitterClient({ cookies: validCookies });
|
||||
const client = new TwitterClient({ relayBaseUrl: testRelayBaseUrl });
|
||||
const clientPrivate = client as unknown as TwitterClientPrivate;
|
||||
clientPrivate.getListTimelineQueryIds = async () => ['test'];
|
||||
|
||||
@@ -134,7 +134,7 @@ describe('TwitterClient lists timeline', () => {
|
||||
}),
|
||||
});
|
||||
|
||||
const client = new TwitterClient({ cookies: validCookies });
|
||||
const client = new TwitterClient({ relayBaseUrl: testRelayBaseUrl });
|
||||
const clientPrivate = client as unknown as TwitterClientPrivate;
|
||||
clientPrivate.getListTimelineQueryIds = async () => ['test'];
|
||||
|
||||
@@ -199,7 +199,7 @@ describe('TwitterClient lists timeline', () => {
|
||||
}),
|
||||
});
|
||||
|
||||
const client = new TwitterClient({ cookies: validCookies });
|
||||
const client = new TwitterClient({ relayBaseUrl: testRelayBaseUrl });
|
||||
const clientPrivate = client as unknown as TwitterClientPrivate;
|
||||
clientPrivate.getListTimelineQueryIds = async () => ['test'];
|
||||
clientPrivate.refreshQueryIds = async () => {};
|
||||
|
||||
Reference in New Issue
Block a user