File tree Expand file tree Collapse file tree 2 files changed +19
-0
lines changed
Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -84,6 +84,7 @@ export default Ember.Service.extend({
8484 response : readOnly ( '_fastbootInfo.response' ) ,
8585
8686 request : computed ( function ( ) {
87+ if ( ! get ( this , 'isFastBoot' ) ) return null ;
8788 return RequestObject . create ( { request : get ( this , '_fastbootInfo.request' ) } ) ;
8889 } ) ,
8990
Original file line number Diff line number Diff line change 1+ import { moduleFor , test } from 'ember-qunit' ;
2+
3+ moduleFor ( 'service:fastboot' , 'Unit | Service | fastboot in the browser' , { } ) ;
4+
5+ test ( 'isFastBoot' , function ( assert ) {
6+ let service = this . subject ( ) ;
7+ assert . equal ( service . get ( 'isFastBoot' ) , false , `it should be false` ) ;
8+ } ) ;
9+
10+ test ( 'request' , function ( assert ) {
11+ let service = this . subject ( ) ;
12+ assert . equal ( service . get ( 'request' ) , null , `it should be null` ) ;
13+ } ) ;
14+
15+ test ( 'response' , function ( assert ) {
16+ let service = this . subject ( ) ;
17+ assert . equal ( service . get ( 'response' ) , null , `it should be null` ) ;
18+ } ) ;
You can’t perform that action at this time.
0 commit comments