@@ -7,53 +7,72 @@ import { provideHttpClientTesting } from '@angular/common/http/testing';
77import { ToastrModule } from 'ngx-toastr' ;
88
99describe ( 'SceneFilesComponent' , ( ) => {
10- let component : SceneFilesComponent ;
11- let fixture : ComponentFixture < SceneFilesComponent > ;
12- beforeEach ( ( ) => {
13- TestBed . configureTestingModule ( {
14- imports : [ SceneFilesModule ,
15- ToastrModule . forRoot ( {
16- positionClass : 'toast-bottom-right'
17- } )
18- ] ,
19- providers : [
20- provideMockStore ( ) ,
21- provideHttpClient ( ) ,
22- provideHttpClientTesting ( ) ,
23- ] ,
24- } ) ;
10+ let component : SceneFilesComponent ;
11+ let fixture : ComponentFixture < SceneFilesComponent > ;
12+ beforeEach ( ( ) => {
13+ TestBed . configureTestingModule ( {
14+ imports : [
15+ SceneFilesModule ,
16+ ToastrModule . forRoot ( {
17+ positionClass : 'toast-bottom-right' ,
18+ } ) ,
19+ ] ,
20+ providers : [
21+ provideMockStore ( ) ,
22+ provideHttpClient ( ) ,
23+ provideHttpClientTesting ( ) ,
24+ ] ,
2525 } ) ;
26+ } ) ;
2627
27- beforeEach ( ( ) => { fixture = TestBed . createComponent ( SceneFilesComponent ) ; component = fixture . componentInstance ; fixture . detectChanges ( ) ; } ) ;
28+ beforeEach ( ( ) => {
29+ fixture = TestBed . createComponent ( SceneFilesComponent ) ;
30+ component = fixture . componentInstance ;
31+ fixture . detectChanges ( ) ;
32+ } ) ;
2833
29- it ( 'should create' , ( ) => { expect ( component ) . toBeDefined ( ) ; } ) ;
34+ it ( 'should create' , ( ) => {
35+ expect ( component ) . toBeDefined ( ) ;
36+ } ) ;
3037
31- it ( 'should be able to generate params for L2 GSLC equivalent of L1 RSLC products' , ( ) => expect (
32- component . getNisarL2Params ( 'NISAR_L1_PR_RSLC_088_039_D_114_2005_SHSH_A_20251114T222008_20251114T222017_T05000_N_P_J_001' , 'RSLC' ) ) . toEqual (
33- ( {
34- granule_list : 'NISAR_L2_PR_GSLC_088_039_D_114_2005_SHSH_A_20251114T222008_20251114T222017_T05000_N_P_J_001'
35- } )
36- )
37- )
38- it ( 'should be able to generate params for L2 GUNW equivalent of L1 RUNW products' , ( ) => expect (
39- component . getNisarL2Params ( 'NISAR_L1_PR_RUNW_015_156_A_010_016_2000_SV_20230619T000803_20230619T000817_20230701T000803_20230701T000817_T00406_N_P_J_001' , 'RUNW' ) ) . toEqual (
40- ( {
41- granule_list : 'NISAR_L2_PR_GUNW_015_156_A_010_016_2000_SV_20230619T000803_20230619T000817_20230701T000803_20230701T000817_T00406_N_P_J_001'
42- } )
43- )
44- )
45- it ( 'should be able to generate params for L2 GOFF equivalent of L1 ROFF products' , ( ) => expect (
46- component . getNisarL2Params ( 'NISAR_L1_PR_ROFF_039_002_D_123_040_4000_SH_20240403T084941_20240403T084954_20240415T084941_20240415T084954_T00408_N_P_J_001' , 'ROFF' ) ) . toEqual (
47- ( {
48- granule_list : 'NISAR_L2_PR_GOFF_039_002_D_123_040_4000_SH_20240403T084941_20240403T084954_20240415T084941_20240415T084954_T00408_N_P_J_001'
49- } )
50- )
51- )
52- it ( 'should be able to generate params for L2 UR equivalent of L1 UR products' , ( ) => expect (
53- component . getNisarL2Params ( 'NISAR_L1_UR_ROFF_039_002_D_121_040_7700_SH_20240403T084849_20240403T084905_20240415T084849_20240415T084905_T00408_F_P_J_001' , 'ROFF' ) ) . toEqual (
54- ( {
55- granule_list : 'NISAR_L2_UR_GOFF_039_002_D_121_040_7700_SH_20240403T084849_20240403T084905_20240415T084849_20240415T084905_T00408_F_P_J_001'
56- } )
57- )
58- )
59- } )
38+ it ( 'should be able to generate params for L2 GSLC equivalent of L1 RSLC products' , ( ) =>
39+ expect (
40+ component . getNisarL2Params (
41+ 'NISAR_L1_PR_RSLC_088_039_D_114_2005_SHSH_A_20251114T222008_20251114T222017_T05000_N_P_J_001' ,
42+ 'RSLC' ,
43+ ) ,
44+ ) . toEqual ( {
45+ granule_list :
46+ 'NISAR_L2_PR_GSLC_088_039_D_114_2005_SHSH_A_20251114T222008_20251114T222017_T05000_N_P_J_001' ,
47+ } ) ) ;
48+ it ( 'should be able to generate params for L2 GUNW equivalent of L1 RUNW products' , ( ) =>
49+ expect (
50+ component . getNisarL2Params (
51+ 'NISAR_L1_PR_RUNW_015_156_A_010_016_2000_SV_20230619T000803_20230619T000817_20230701T000803_20230701T000817_T00406_N_P_J_001' ,
52+ 'RUNW' ,
53+ ) ,
54+ ) . toEqual ( {
55+ granule_list :
56+ 'NISAR_L2_PR_GUNW_015_156_A_010_016_2000_SV_20230619T000803_20230619T000817_20230701T000803_20230701T000817_T00406_N_P_J_001' ,
57+ } ) ) ;
58+ it ( 'should be able to generate params for L2 GOFF equivalent of L1 ROFF products' , ( ) =>
59+ expect (
60+ component . getNisarL2Params (
61+ 'NISAR_L1_PR_ROFF_039_002_D_123_040_4000_SH_20240403T084941_20240403T084954_20240415T084941_20240415T084954_T00408_N_P_J_001' ,
62+ 'ROFF' ,
63+ ) ,
64+ ) . toEqual ( {
65+ granule_list :
66+ 'NISAR_L2_PR_GOFF_039_002_D_123_040_4000_SH_20240403T084941_20240403T084954_20240415T084941_20240415T084954_T00408_N_P_J_001' ,
67+ } ) ) ;
68+ it ( 'should be able to generate params for L2 UR equivalent of L1 UR products' , ( ) =>
69+ expect (
70+ component . getNisarL2Params (
71+ 'NISAR_L1_UR_ROFF_039_002_D_121_040_7700_SH_20240403T084849_20240403T084905_20240415T084849_20240415T084905_T00408_F_P_J_001' ,
72+ 'ROFF' ,
73+ ) ,
74+ ) . toEqual ( {
75+ granule_list :
76+ 'NISAR_L2_UR_GOFF_039_002_D_121_040_7700_SH_20240403T084849_20240403T084905_20240415T084849_20240415T084905_T00408_F_P_J_001' ,
77+ } ) ) ;
78+ } ) ;
0 commit comments