File tree Expand file tree Collapse file tree 1 file changed +19
-1
lines changed
packages/analytics/testing Expand file tree Collapse file tree 1 file changed +19
-1
lines changed Original file line number Diff line number Diff line change 1515 * limitations under the License.
1616 */
1717
18- import { FirebaseApp , initializeApp , _registerComponent } from '@firebase/app' ;
18+ import {
19+ FirebaseApp ,
20+ initializeApp ,
21+ _registerComponent ,
22+ _addOrOverwriteComponent
23+ } from '@firebase/app' ;
1924import { Component , ComponentType } from '@firebase/component' ;
2025import { _FirebaseInstallationsInternal } from '@firebase/installations' ;
2126import { AnalyticsService } from '../src/factory' ;
@@ -78,5 +83,18 @@ export function getFullApp(fakeAppParams?: {
7883 )
7984 ) ;
8085 const app = initializeApp ( { ...fakeConfig , ...fakeAppParams } ) ;
86+ _addOrOverwriteComponent (
87+ app ,
88+ //@ts -ignore
89+ new Component (
90+ 'heartbeat' ,
91+ ( ) => {
92+ return {
93+ triggerHeartbeat : ( ) => { }
94+ } as any ;
95+ } ,
96+ ComponentType . PUBLIC
97+ )
98+ ) ;
8199 return app ;
82100}
You can’t perform that action at this time.
0 commit comments