File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ import { LoaderService } from '../../service/loader/data-loader.service';
1515import { MockLoaderService } from '../../service/loader/mock-data-loader.service' ;
1616import { Data } from 'src/app/model/activity-store' ;
1717import { ModalMessageComponent } from 'src/app/component/modal-message/modal-message.component' ;
18+ import { GithubService } from 'src/app/service/settings/github.service' ;
1819
1920let mockLoaderService : MockLoaderService ;
2021const MOCK_DATA = {
@@ -66,13 +67,24 @@ describe('SettingsComponent', () => {
6667 { provide : SettingsService , useValue : settingsService } ,
6768 { provide : LoaderService , useValue : mockLoaderService } ,
6869 { provide : ModalMessageComponent , useValue : modalComponent } ,
70+ {
71+ provide : GithubService ,
72+ useValue : jasmine . createSpyObj ( 'GithubService' , [ 'getLatestRelease' ] ) ,
73+ } ,
6974 ] ,
7075 } ) . compileComponents ( ) ;
7176 } ) ;
7277
7378 beforeEach ( fakeAsync ( ( ) => {
7479 fixture = TestBed . createComponent ( SettingsComponent ) ;
7580 component = fixture . componentInstance ;
81+ component . meta = {
82+ activityMeta : null ,
83+ activityFiles : [ ] ,
84+ progressDefinition : { } ,
85+ saveProgressDefinition : jasmine . createSpy ( 'saveProgressDefinition' ) ,
86+ } as any ;
87+
7688 fixture . detectChanges ( ) ;
7789 tick ( ) ;
7890 fixture . detectChanges ( ) ;
You can’t perform that action at this time.
0 commit comments