Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix deprecation warnings in tests #158

Merged
merged 2 commits into from
May 22, 2024

Conversation

pjonsson
Copy link
Contributor

@pjonsson pjonsson commented May 1, 2024

No description provided.

Buffer() is deprecated according to
the warnings when running tests.
const responseStatus = req.headers['x-give-response-status'] || 200;
const responseStatus = parseInt(req.headers['x-give-response-status'] || "200");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch, just a tiny nitpick - could this be const responseStatus = parseInt(req.headers['x-give-response-status']) || 200 instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

This is required to be an int, so
make it an int on construction.
@pjonsson pjonsson force-pushed the test-deprecation-fixes branch from 743841f to a3b1ece Compare May 22, 2024 07:02
Copy link
Contributor

@na9da na9da left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks for the PR!

@na9da na9da merged commit 3b66d7c into TerriaJS:master May 22, 2024
3 checks passed
@pjonsson pjonsson deleted the test-deprecation-fixes branch May 23, 2024 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants