Skip to content

Commit

Permalink
[EngSys] Simplify mocking of github.paginate (#32648)
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeharder authored Feb 16, 2025
1 parent 83a2ab4 commit f667483
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion .github/test/mocks.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export function createMockGithub() {
const data = (await func(params)).data;

// Simulate normalization performed by real impl
return data.artifacts || data.workflow_runs || data.check_runs || data;
return Array.isArray(data) ? data : data[Object.keys(data)[0]];
},
rest: {
actions: {
Expand Down

0 comments on commit f667483

Please sign in to comment.