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

feat: add support for wildcard "all" routes #536

Merged
merged 3 commits into from
Jul 21, 2020
Merged

feat: add support for wildcard "all" routes #536

merged 3 commits into from
Jul 21, 2020

Conversation

ArthurMelin
Copy link
Contributor

I added support for routes which match all HTTP methods.

A change to the action type vs. request method check in routeHandler in the Express driver was required. However, being unfamiliar with the project source I'm not entirely sure this is the only location where such a change is required.

@jotamorais
Copy link
Member

This PR has been merged onto next branch and a release candidate published - 0.9.0-alpha.1.

@Elassyo, would you be so kind as to add some test coverage as well?

Thank you!

@ArthurMelin
Copy link
Contributor Author

Just added a test for the decorator, however I had to write a fix to prevent multiple routes from matching the same request, I put it in a separate PR (#568).
The test I added won't pass without it because the test route I added All(/users/me) also get matched by Get(/users/:id).

@jotamorais
Copy link
Member

Just added a test for the decorator, however I had to write a fix to prevent multiple routes from matching the same request, I put it in a separate PR (#568).
The test I added won't pass without it because the test route I added All(/users/me) also get matched by Get(/users/:id).

Thanks @Elassyo. I merged #568 in and this one as well in the next branch and published 0.9.0-alpha.2 for tests before merging it into master and release final stable 0.9.0.

Please, help with tests and let me know if you find something.

Thanks again!

@jotamorais jotamorais merged commit 7fc4728 into typestack:master Jul 21, 2020
@NoNameProvided NoNameProvided changed the title Add support for wildcard "all" routes feat: add support for wildcard "all" routes Aug 9, 2020
@github-actions
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: feature Issues related to new features.
2 participants