Repository navigation
Add tests of HTTP normalization on app level - #3527
Conversation
|
Can one of the admins verify this patch? To accept patch and trigger a build add comment ".ok\W+to\W+test." |
|
Can one of the admins verify this patch? |
3 similar comments
|
Can one of the admins verify this patch? |
|
Can one of the admins verify this patch? |
|
Can one of the admins verify this patch? |
|
@slnode ok to test |
bajtos
left a comment
There was a problem hiding this comment.
Looks mostly good, could you please improve the coding style little bit per my comments below?
Let's wait with landing this patch until strongloop/strong-remoting#410 is landed and released.
| }); | ||
|
|
||
| describe( | ||
| '`Model.remoting.normalizeHttpPath` and `app.remoting.rest.normalizeHttpPath` options', |
There was a problem hiding this comment.
Let's shorten this title to something like Model-level and app-level normalizeHttpPath option
| }); | ||
|
|
||
| it.onServer( | ||
| 'should give `Model.remoting.normalizeHttpPath` precedence over ' + |
There was a problem hiding this comment.
We are trying to avoid should prefix in new test names, see http://loopback.io/doc/en/contrib/style-guide.html. This applies to other test names added by this pull request too.
I am proposing to shorten the test name too, e.g. prioritizes model-level setting over the app-level one.
The full test name will include the title from describe, which already contains normalizeHttpPath. No need to repeat it here again...
...Model-level and app-level normalizeHttpPath option prioritizes model-level setting over the app-level one
bajtos
left a comment
There was a problem hiding this comment.
Thank you for the update, the changes LGTM now 👍
Let's wait until strongloop/strong-remoting#410 is landed to verify the new tests are passing on all our CI platforms.
|
@slnode test please |
Also improve tests on model level to include nested routes Add a test for HTTP normalization precedence too.
|
Landed, thank you! |
Description
As discussed in #608 (comment), this PR adds and improves tests for HTTP normalization both on application and model level, including tests for nested routes. Please note that these tests require the changes in strongloop/strong-remoting#410 to not fail.
Related issues
#608, strongloop/strong-remoting#410
Checklist
guide