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

Validate our responses with Rack::Lint in tests #563

Open
nateberkopec opened this issue Mar 28, 2023 · 3 comments
Open

Validate our responses with Rack::Lint in tests #563

nateberkopec opened this issue Mar 28, 2023 · 3 comments

Comments

@nateberkopec
Copy link
Collaborator

nateberkopec commented Mar 28, 2023

https://github.com/rack/rack/blob/main/lib/rack/lint.rb

In tests

@keshavbiswa
Copy link
Contributor

Not sure where to add this.

@keshavbiswa
Copy link
Contributor

keshavbiswa commented Mar 31, 2023

Does something like this work?

          # Validate using Rack::Lint
          if config.rack_lint_enabled # rack_lint_enabled is set to true by default
            status, headers, body = Rack::Lint.new(@app).call(env)
          else
            status, headers, body = @app.call(env)
          end

@nateberkopec

@nateberkopec
Copy link
Collaborator Author

Ah sorry - I should've been more specific. This should only be added to our test suite.

@nateberkopec nateberkopec changed the title Validate our responses with Rack::Lint Validate our responses with Rack::Lint in tests Apr 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants