fix(gerrit): not auto-merging if Code-Review changed from +2 to +1 #68545
Annotations
3 errors
lib/modules/platform/gerrit/client.spec.ts#L443
expect(received).toResolve()
Expected promise to resolve, however it rejected.
at Object.<anonymous> (lib/modules/platform/gerrit/client.spec.ts:443:50)
|
lib/modules/platform/gerrit/client.spec.ts#L428
*** Missing HTTP mocks ***
- POST https://dev.gerrit.com/renovate/a/changes/123456/revisions/current/review
Requests done:
- GET https://dev.gerrit.com/renovate/a/changes/123456?o=SUBMITTABLE&o=CHECK&o=MESSAGES&o=DETAILED_ACCOUNTS&o=LABELS&o=CURRENT_ACTIONS&o=CURRENT_REVISION&o=CURRENT_COMMIT&o=DETAILED_LABELS [200]
---
Renovate testing strategy requires that every HTTP request
has a corresponding mock.
This error occurs when some of the request aren't mocked.
Let's suppose your code performs two HTTP calls:
GET https://example.com/foo/bar/fail 404 <without body>
POST https://example.com/foo/bar/success 200 { "ok": true }
The unit test should have this mock:
httpMock.scope('https://example.com/foo/bar')
.get('/fail')
.reply(404)
.post('/success')
.reply(200, { ok: true });
Note: `httpMock.scope(...)` is the Renovate-specific construct.
The scope object itself is provided by the `nock` library.
Details: https://github.com/nock/nock#usage
at <test> (lib/modules/platform/gerrit/client.spec.ts:428:9)
|
|
The logs for this run have expired and are no longer available.
Loading