Skip to content

Commit

Permalink
test: remove --timeout and fix disabling throttling (#656)
Browse files Browse the repository at this point in the history
  • Loading branch information
gr2m authored Feb 10, 2024
1 parent 70b9da8 commit bc3d1bf
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 17 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"main": "index.js",
"scripts": {
"start": "probot run ./index.js",
"test": "tap test/**/*-test.js --timeout 240",
"test": "tap test/**/*-test.js",
"posttest": "npm run lint",
"coverage-report": "npx tap report --coverage-report lcov",
"lint": "prettier --check '{lib,test}/**/*.{js,json,ts}' index.js *.md package.json",
Expand Down
11 changes: 7 additions & 4 deletions test/integration/free-plan-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,13 @@ beforeEach(async () => {
probot = new Probot({
id: 1,
githubToken: "test",
Octokit: ProbotOctokit.defaults({
throttle: { enabled: false },
retry: { enabled: false },
log: pino(streamLogsToOutput),
Octokit: ProbotOctokit.defaults((instanceOptions) => {
return {
...instanceOptions,
throttle: { enabled: false },
retry: { enabled: false },
log: pino(streamLogsToOutput),
};
}),
log: pino(streamLogsToOutput),
});
Expand Down
11 changes: 7 additions & 4 deletions test/integration/installation-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,13 @@ beforeEach(function () {
probot = new Probot({
id: 1,
githubToken: "test",
Octokit: ProbotOctokit.defaults({
throttle: { enabled: false },
retry: { enabled: false },
log: pino(streamLogsToOutput),
Octokit: ProbotOctokit.defaults((instanceOptions) => {
return {
...instanceOptions,
throttle: { enabled: false },
retry: { enabled: false },
log: pino(streamLogsToOutput),
};
}),
log: pino(streamLogsToOutput),
});
Expand Down
11 changes: 7 additions & 4 deletions test/integration/marketplace-purchase-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,13 @@ beforeEach(function () {
probot = new Probot({
id: 1,
githubToken: "test",
Octokit: ProbotOctokit.defaults({
throttle: { enabled: false },
retry: { enabled: false },
log: pino(streamLogsToOutput),
Octokit: ProbotOctokit.defaults((instanceOptions) => {
return {
...instanceOptions,
throttle: { enabled: false },
retry: { enabled: false },
log: pino(streamLogsToOutput),
};
}),
log: pino(streamLogsToOutput),
});
Expand Down
11 changes: 7 additions & 4 deletions test/integration/pro-plan-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,13 @@ beforeEach(function () {
probot = new Probot({
id: 1,
githubToken: "test",
Octokit: ProbotOctokit.defaults({
throttle: { enabled: false },
retry: { enabled: false },
log: pino(streamLogsToOutput),
Octokit: ProbotOctokit.defaults((instanceOptions) => {
return {
...instanceOptions,
throttle: { enabled: false },
retry: { enabled: false },
log: pino(streamLogsToOutput),
};
}),
log: pino(streamLogsToOutput),
});
Expand Down

0 comments on commit bc3d1bf

Please sign in to comment.