我正在docker-compose上进行测试。我遍历了代码的每个部分并进行了测试,并且不断收到这个奇怪的错误Timeout - Async callback was not invoked within the 10000ms timeout specified by jest.setTimeout.Error:
,这是我的测试的样子
describe("Transactions", () => {
test("it should only show transactions for accounts that the user has permissions for", async () => {
//jest.setTimeout(10000);
const account = "0071326981";
const accountInfo = mockTransactions(account);
const authRequest = mockTransactionQuery(account);
const token = await createHeadlessSession({ ...user, ...mockTransactionsSession(account, true) }, env.service_secret);
mockGetAccount(account, accountInfo);
await request
.get("/api/v1/transactions")
.set("Authorization", `${env.auth_scheme} ${token}`)
.query(authRequest)
.expect(OK);
});