File tree Expand file tree Collapse file tree 1 file changed +16
-7
lines changed Expand file tree Collapse file tree 1 file changed +16
-7
lines changed Original file line number Diff line number Diff line change @@ -399,12 +399,21 @@ describe('Simple base routes', () => {
399
399
. expect ( 200 ) ;
400
400
} ) ;
401
401
402
- it ( 'deep relations' , ( ) => {
403
- return request ( server )
404
- . get ( '/companies/1?join=users||email&join=users.projects&join=users.projects.tasks' )
405
- . expect ( 200 )
406
- . expect ( res => {
407
- expect ( res . body ) . to . have . nested . property ( 'users[0].projects[0].tasks[0].name' ) ;
408
- } ) ;
402
+ describe ( 'nested relations' , ( ) => {
403
+ it ( 'nested relations' , ( ) => {
404
+ return request ( server )
405
+ . get ( '/companies/1?join=users||email&join=users.projects&join=users.projects.tasks' )
406
+ . expect ( 200 )
407
+ . expect ( res => {
408
+ expect ( res . body ) . to . have . nested . property ( 'users[0].projects[0].tasks[0].name' ) ;
409
+ } ) ;
410
+ } ) ;
411
+
412
+ it ( 'when missing fields' , ( ) => {
413
+ return request ( server )
414
+ . get ( '/companies/1?join=users||email&join=users.projects1&join=users.projects1.tasks' )
415
+ . expect ( 200 ) ;
416
+ } ) ;
409
417
} ) ;
418
+
410
419
} ) ;
You can’t perform that action at this time.
0 commit comments