Skip to content

Commit 26ab83b

Browse files
committed
test(release): satisfy retry lint contract
1 parent e88ec99 commit 26ab83b

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

tests/assert-release-published.test.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -140,16 +140,17 @@ describe('release publication assertion', () => {
140140

141141
const result = await waitForPublishedArtifact(
142142
'npm provenance',
143-
async () => {
143+
() => {
144144
checks += 1;
145145
if (checks < 3) throw new Error('HTTP 404: Not found');
146146
return 'ready';
147147
},
148148
{
149149
attempts: 3,
150150
delayMs: 25,
151-
sleep: async (delay) => {
151+
sleep: (delay) => {
152152
delays.push(delay);
153+
return Promise.resolve();
153154
},
154155
}
155156
);
@@ -165,14 +166,14 @@ describe('release publication assertion', () => {
165166
await assert.rejects(
166167
waitForPublishedArtifact(
167168
'npm provenance',
168-
async () => {
169+
() => {
169170
checks += 1;
170171
throw new Error(`not ready ${checks}`);
171172
},
172173
{
173174
attempts: 2,
174175
delayMs: 0,
175-
sleep: async () => {},
176+
sleep: () => Promise.resolve(),
176177
}
177178
),
178179
/npm provenance did not become ready after 2 attempts: not ready 2/

0 commit comments

Comments
 (0)