fixed last failing test in backend-common
Signed-off-by: Simon <simme.jakobsson@gmail.com>
This commit is contained in:
@@ -26,6 +26,7 @@ import { getVoidLogger } from '../logging';
|
||||
import { GitlabUrlReader } from './GitlabUrlReader';
|
||||
import { DefaultReadTreeResponseFactory } from './tree';
|
||||
import { NotModifiedError, NotFoundError } from '@backstage/errors';
|
||||
import getRawBody from 'raw-body';
|
||||
import {
|
||||
GitLabIntegration,
|
||||
readGitLabIntegrationConfig,
|
||||
@@ -151,7 +152,8 @@ describe('GitlabUrlReader', () => {
|
||||
});
|
||||
|
||||
const data = await reader.readUrl(url);
|
||||
const res = await JSON.parse(data.toString());
|
||||
const fromStream = await getRawBody(data.stream!());
|
||||
const res = await JSON.parse(fromStream.toString());
|
||||
expect(res).toEqual(response);
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user