chore/cli: Replace msw with setupRequestMockHandlers

Signed-off-by: Johan Haals <johan.haals@gmail.com>
This commit is contained in:
Johan Haals
2021-10-26 10:38:13 +02:00
parent 2ba4a2caef
commit f1e96dc5b1
29 changed files with 74 additions and 57 deletions
+2 -2
View File
@@ -14,7 +14,7 @@
* limitations under the License.
*/
import { msw } from '@backstage/test-utils';
import { setupRequestMockHandlers } from '@backstage/test-utils';
import { rest } from 'msw';
import { setupServer } from 'msw/node';
import { FindingSummary, FossaApi, FossaClient } from './index';
@@ -40,7 +40,7 @@ const identityApi: IdentityApi = {
};
describe('FossaClient', () => {
msw.setupDefaultHandlers(server);
setupRequestMockHandlers(server);
const mockBaseUrl = 'http://backstage:9191/api/proxy';
const discoveryApi = UrlPatternDiscovery.compile(mockBaseUrl);