@@ -30,32 +30,32 @@ describe('MatProgressSpinner', () => {
30
30
} ) ) ;
31
31
32
32
it ( 'should apply a mode of "determinate" if no mode is provided.' , ( ) => {
33
- let fixture = TestBed . createComponent ( BasicProgressSpinner ) ;
33
+ const fixture = TestBed . createComponent ( BasicProgressSpinner ) ;
34
34
fixture . detectChanges ( ) ;
35
35
36
- let progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
36
+ const progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
37
37
expect ( progressElement . componentInstance . mode ) . toBe ( 'determinate' ) ;
38
38
} ) ;
39
39
40
40
it ( 'should not modify the mode if a valid mode is provided.' , ( ) => {
41
- let fixture = TestBed . createComponent ( IndeterminateProgressSpinner ) ;
41
+ const fixture = TestBed . createComponent ( IndeterminateProgressSpinner ) ;
42
42
fixture . detectChanges ( ) ;
43
43
44
- let progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
44
+ const progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
45
45
expect ( progressElement . componentInstance . mode ) . toBe ( 'indeterminate' ) ;
46
46
} ) ;
47
47
48
48
it ( 'should define a default value of zero for the value attribute' , ( ) => {
49
- let fixture = TestBed . createComponent ( BasicProgressSpinner ) ;
49
+ const fixture = TestBed . createComponent ( BasicProgressSpinner ) ;
50
50
fixture . detectChanges ( ) ;
51
51
52
- let progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
52
+ const progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
53
53
expect ( progressElement . componentInstance . value ) . toBe ( 0 ) ;
54
54
} ) ;
55
55
56
56
it ( 'should set the value to 0 when the mode is set to indeterminate' , ( ) => {
57
- let fixture = TestBed . createComponent ( ProgressSpinnerWithValueAndBoundMode ) ;
58
- let progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
57
+ const fixture = TestBed . createComponent ( ProgressSpinnerWithValueAndBoundMode ) ;
58
+ const progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
59
59
fixture . componentInstance . mode = 'determinate' ;
60
60
fixture . detectChanges ( ) ;
61
61
@@ -66,8 +66,8 @@ describe('MatProgressSpinner', () => {
66
66
} ) ;
67
67
68
68
it ( 'should retain the value if it updates while indeterminate' , ( ) => {
69
- let fixture = TestBed . createComponent ( ProgressSpinnerWithValueAndBoundMode ) ;
70
- let progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
69
+ const fixture = TestBed . createComponent ( ProgressSpinnerWithValueAndBoundMode ) ;
70
+ const progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
71
71
72
72
fixture . componentInstance . mode = 'determinate' ;
73
73
fixture . detectChanges ( ) ;
@@ -105,11 +105,11 @@ describe('MatProgressSpinner', () => {
105
105
} ) ;
106
106
107
107
it ( 'should clamp the value of the progress between 0 and 100' , ( ) => {
108
- let fixture = TestBed . createComponent ( BasicProgressSpinner ) ;
108
+ const fixture = TestBed . createComponent ( BasicProgressSpinner ) ;
109
109
fixture . detectChanges ( ) ;
110
110
111
- let progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
112
- let progressComponent = progressElement . componentInstance ;
111
+ const progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
112
+ const progressComponent = progressElement . componentInstance ;
113
113
114
114
progressComponent . value = 50 ;
115
115
expect ( progressComponent . value ) . toBe ( 50 ) ;
@@ -281,10 +281,10 @@ describe('MatProgressSpinner', () => {
281
281
} ) ;
282
282
283
283
it ( 'should set the color class on the mat-spinner' , ( ) => {
284
- let fixture = TestBed . createComponent ( SpinnerWithColor ) ;
284
+ const fixture = TestBed . createComponent ( SpinnerWithColor ) ;
285
285
fixture . detectChanges ( ) ;
286
286
287
- let progressElement = fixture . debugElement . query ( By . css ( 'mat-spinner' ) ) ! ;
287
+ const progressElement = fixture . debugElement . query ( By . css ( 'mat-spinner' ) ) ! ;
288
288
289
289
expect ( progressElement . nativeElement . classList ) . toContain ( 'mat-primary' ) ;
290
290
@@ -296,10 +296,10 @@ describe('MatProgressSpinner', () => {
296
296
} ) ;
297
297
298
298
it ( 'should set the color class on the mat-progress-spinner' , ( ) => {
299
- let fixture = TestBed . createComponent ( ProgressSpinnerWithColor ) ;
299
+ const fixture = TestBed . createComponent ( ProgressSpinnerWithColor ) ;
300
300
fixture . detectChanges ( ) ;
301
301
302
- let progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
302
+ const progressElement = fixture . debugElement . query ( By . css ( 'mat-progress-spinner' ) ) ! ;
303
303
304
304
expect ( progressElement . nativeElement . classList ) . toContain ( 'mat-primary' ) ;
305
305
@@ -337,8 +337,8 @@ describe('MatProgressSpinner', () => {
337
337
} ) ;
338
338
339
339
it ( 'should update the element size when changed dynamically' , ( ) => {
340
- let fixture = TestBed . createComponent ( BasicProgressSpinner ) ;
341
- let spinner = fixture . debugElement . query ( By . directive ( MatProgressSpinner ) ) ! ;
340
+ const fixture = TestBed . createComponent ( BasicProgressSpinner ) ;
341
+ const spinner = fixture . debugElement . query ( By . directive ( MatProgressSpinner ) ) ! ;
342
342
spinner . componentInstance . diameter = 32 ;
343
343
fixture . detectChanges ( ) ;
344
344
expect ( spinner . nativeElement . style . width ) . toBe ( '32px' ) ;
0 commit comments