AAE-30882 Remove superagent for fetch (#11856)

* [AAE-30882] - Remove superagent for fetch

* [AAE-30882] - Fixing comments

* [AAE-30882] - fixde failing unit tests

* [AAE-30882] - fixde failing unit tests

* [AAE-30882] - fixd sonarcloud comment
This commit is contained in:
Vito Albano
2026-05-07 09:12:07 +01:00
committed by GitHub
parent 9cdacf3ebf
commit 57bf066164
54 changed files with 2127 additions and 922 deletions
@@ -167,7 +167,7 @@ describe('Node', () => {
nodesApi.initiateFolderSizeCalculation('b4cff62a-664d-4d45-9302-98723eac1319').then(
() => {},
(err) => {
const { error } = JSON.parse(err.response.text);
const { error } = JSON.parse(err.message);
assert.equal(error.statusCode, 404);
assert.equal(error.errorKey, 'framework.exception.EntityNotFound');
assert.equal(error.briefSummary, '11207522 The entity with id: b4cff62a-664d-4d45-9302-98723eac1319 was not found');
@@ -196,7 +196,7 @@ describe('Node', () => {
nodesApi.getFolderSizeInfo('b4cff62a-664d-4d45-9302-98723eac1319', '5ade426e-8a04-4d50-9e42-6e8a041d50f3').then(
() => {},
(err) => {
const { error } = JSON.parse(err.response.text);
const { error } = JSON.parse(err.message);
assert.equal(error.statusCode, 404);
assert.equal(error.errorKey, 'jobId does not exist');
assert.equal(error.briefSummary, '11207212 jobId does not exist');
@@ -60,9 +60,13 @@ describe('PeopleApi', () => {
it('should get list of people', (done) => {
peopleMock.get200ResponsePersons();
peopleApi.listPeople().then(() => {
peopleMock.play();
done();
});
peopleApi.listPeople().then(
() => {
done();
},
(err) => {
done(new Error('listPeople rejected: ' + JSON.stringify(err)));
}
);
});
});