Skip to content

Commit

Permalink
feat: change browser, scripted and multihttp timeouts up to 120s (#1065)
Browse files Browse the repository at this point in the history
  • Loading branch information
VikaCep authored Feb 11, 2025
1 parent 427e834 commit ff377b6
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 10 deletions.
6 changes: 3 additions & 3 deletions src/components/CheckForm/CheckForm.constants.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ const CheckTimeoutValues = {
[CheckType.DNS]: { min: 1, max: 60 },
[CheckType.GRPC]: { min: 1, max: 60 },
[CheckType.HTTP]: { min: 1, max: 60 },
[CheckType.MULTI_HTTP]: { min: 5, max: 90 },
[CheckType.Scripted]: { min: 5, max: 90 },
[CheckType.Browser]: { min: 5, max: 90 },
[CheckType.MULTI_HTTP]: { min: 5, max: 120 },
[CheckType.Scripted]: { min: 5, max: 120 },
[CheckType.Browser]: { min: 5, max: 120 },
};

export { CheckTimeoutValues };
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ describe(`BrowserCheck - Section 5 (Execution) payload`, () => {
expect(body.frequency).toBe(ONE_MINUTE_IN_MS);
});

it(`can add timeout up to 90 seconds`, async () => {
const MAX_TIMEOUT_MS = 90000;
it(`can add timeout up to 120 seconds`, async () => {
const MAX_TIMEOUT_MS = 120000;

const { user, read } = await renderNewForm(checkType);
await fillMandatoryFields({ user, checkType });
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ describe(`MultiHTTPCheck - Section 5 (Execution) payload`, () => {
expect(body.frequency).toBe(ONE_MINUTE_IN_MS);
});

it(`can add timeout up to 90 seconds`, async () => {
const MAX_TIMEOUT_MS = 90000;
it(`can add timeout up to 120 seconds`, async () => {
const MAX_TIMEOUT_MS = 120000;

const { user, read } = await renderNewForm(checkType);
await fillMandatoryFields({ user, checkType });
Expand Down
2 changes: 1 addition & 1 deletion src/page/NewCheck/__tests__/NewCheck.journey.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ describe(`<NewCheck /> journey`, () => {

const errorMsg = await screen.findByRole('alert');
expect(errorMsg).toBeInTheDocument();
expect(errorMsg).toHaveTextContent(/Frequency must be greater than or equal to timeout \(90 seconds\)/);
expect(errorMsg).toHaveTextContent(/Frequency must be greater than or equal to timeout \(120 seconds\)/);
});

// jsdom doesn't give us back the submitter of the form, so we can't test this
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ describe(`ScriptedCheck - Section 5 (Execution) payload`, () => {
expect(body.frequency).toBe(ONE_MINUTE_IN_MS);
});

it(`can add timeout up to 90 seconds`, async () => {
const MAX_TIMEOUT_MS = 90000;
it(`can add timeout up to 120 seconds`, async () => {
const MAX_TIMEOUT_MS = 120000;

const { user, read } = await renderNewForm(checkType);
await fillMandatoryFields({ user, checkType });
Expand Down

0 comments on commit ff377b6

Please sign in to comment.