Skip to content

Commit

Permalink
Prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
misterbyrne committed Mar 8, 2021
1 parent 25f4703 commit d91adf2
Showing 1 changed file with 13 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -364,42 +364,44 @@ moduleFor(
});
}

async ['@test RouterService#transitionTo should not refresh parent models if the parent query params stay the same'](assert) {
async ['@test RouterService#transitionTo should not refresh parent models if the parent query params stay the same'](
assert
) {
let parentModelHookCallCount = 0;
this.add(
'route:parent',
Route.extend({
queryParams: {
parentParam: {
refreshModel: true
}
refreshModel: true,
},
},
model() {
parentModelHookCallCount++;
return 'model';
}
},
})
);
this.add(
'route:parent.child',
Route.extend({
queryParams: {
childParam: {
refreshModel: true
}
}
refreshModel: true,
},
},
})
);
this.add(
'controller:parent',
Controller.extend({
parentParam: 'parentParamDefaultValue'
parentParam: 'parentParamDefaultValue',
})
);
this.add(
'controller:parent.child',
Controller.extend({
childParam: 'childParamDefaultValue'
childParam: 'childParamDefaultValue',
})
);

Expand All @@ -409,8 +411,8 @@ moduleFor(
try {
await this.routerService.transitionTo('parent.child', {
queryParams: {
childParam: 'nonDefaultValue'
}
childParam: 'nonDefaultValue',
},
});
} catch (e) {
assert.equal(e.message, 'TransitionAborted');
Expand Down

0 comments on commit d91adf2

Please sign in to comment.