AAE-30882 Reduce imports to specfile

This commit is contained in:
Wojciech Duda
2025-02-18 12:15:11 +01:00
parent e6bf6aa46c
commit 4f3a5230b8

View File

@@ -19,7 +19,7 @@ import { SuperagentHttpClient } from '../src/superagentHttpClient';
import { FetchResponse, ofetch } from 'ofetch';
import { RequestOptions } from '../src/api-clients/http-client.interface';
import { Emitters } from '@alfresco/adf-core/api';
import * as utils from '../src/utils';
import { isBrowser } from '../src/utils';
jest.mock('ofetch', () => ({
ofetch: jest.fn()
@@ -177,7 +177,7 @@ describe('SuperagentHttpClient', () => {
};
// Override isBrowser to simulate a non-browser environment
(utils.isBrowser as jest.Mock).mockReturnValue(false);
(isBrowser as jest.Mock).mockReturnValue(false);
const request = client['buildRequest']({
httpMethod,