File tree Expand file tree Collapse file tree
packages/@ember/-internals/environment/lib Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1515 // Test under octane defaults
1616 EmberENV . _DEFAULT_ASYNC_OBSERVERS = true ;
1717
18- // Test for "hooks in EmberENV.EMBER_LOAD_HOOKS['hookName'] get executed"
19- EmberENV . EMBER_LOAD_HOOKS = EmberENV . EMBER_LOAD_HOOKS || { } ;
20- EmberENV . EMBER_LOAD_HOOKS . __before_ember_test_hook__ =
21- EmberENV . EMBER_LOAD_HOOKS . __before_ember_test_hook__ || [ ] ;
22- EmberENV . __test_hook_count__ = 0 ;
23- EmberENV . EMBER_LOAD_HOOKS . __before_ember_test_hook__ . push ( function ( object ) {
24- EmberENV . __test_hook_count__ += object ;
25- } ) ;
26-
2718 // Handle testing feature flags
2819 if ( QUnit . urlParams . ENABLE_OPTIONAL_FEATURES ) {
2920 EmberENV . ENABLE_OPTIONAL_FEATURES = true ;
Original file line number Diff line number Diff line change @@ -144,10 +144,6 @@ export const ENV = {
144144 */
145145 _RERENDER_LOOP_LIMIT : 1000 ,
146146
147- EMBER_LOAD_HOOKS : { } as {
148- [ hook : string ] : Function [ ] ;
149- } ,
150-
151147 FEATURES : { } as {
152148 [ feature : string ] : boolean ;
153149 } ,
@@ -179,18 +175,6 @@ if (typeof EmberENV === 'object' && EmberENV !== null) {
179175 }
180176 }
181177
182- // TODO this does not seem to be used by anything,
183- // can we remove it? do we need to deprecate it?
184- let { EMBER_LOAD_HOOKS } = EmberENV ;
185- if ( typeof EMBER_LOAD_HOOKS === 'object' && EMBER_LOAD_HOOKS !== null ) {
186- for ( let hookName in EMBER_LOAD_HOOKS ) {
187- if ( ! Object . prototype . hasOwnProperty . call ( EMBER_LOAD_HOOKS , hookName ) ) continue ;
188- let hooks = EMBER_LOAD_HOOKS [ hookName ] ;
189- if ( Array . isArray ( hooks ) ) {
190- ENV . EMBER_LOAD_HOOKS [ hookName ] = hooks . filter ( ( hook ) => typeof hook === 'function' ) ;
191- }
192- }
193- }
194178 let { FEATURES } = EmberENV ;
195179 if ( typeof FEATURES === 'object' && FEATURES !== null ) {
196180 for ( let feature in FEATURES ) {
You can’t perform that action at this time.
0 commit comments