@@ -63,9 +63,9 @@ class FakeObservableTreeKeyManagerItem
63
63
64
64
interface ItemConstructorTestContext {
65
65
description : string ;
66
- constructor : new ( label : string ) =>
67
- | FakeArrayTreeKeyManagerItem
68
- | FakeObservableTreeKeyManagerItem ;
66
+ constructor : new (
67
+ label : string ,
68
+ ) => FakeArrayTreeKeyManagerItem | FakeObservableTreeKeyManagerItem ;
69
69
}
70
70
71
71
interface ExpandCollapseKeyEventTestContext {
@@ -167,16 +167,20 @@ describe('TreeKeyManager', () => {
167
167
keyManager . onClick ( itemList . get ( 0 ) ! ) ;
168
168
169
169
expect ( keyManager . getActiveItemIndex ( ) ) . withContext ( 'active item index' ) . toBe ( 0 ) ;
170
- expect ( keyManager . getActiveItem ( ) ?. getLabel ( ) ) . withContext ( 'active item label' ) . toBe ( 'one' ) ;
170
+ expect ( keyManager . getActiveItem ( ) ?. getLabel ( ) )
171
+ . withContext ( 'active item label' )
172
+ . toBe ( 'one' ) ;
171
173
itemList . reset ( [ new FakeObservableTreeKeyManagerItem ( 'parent0' ) , ...itemList . toArray ( ) ] ) ;
172
174
itemList . notifyOnChanges ( ) ;
173
175
174
176
expect ( keyManager . getActiveItemIndex ( ) ) . withContext ( 'active item index' ) . toBe ( 1 ) ;
175
- expect ( keyManager . getActiveItem ( ) ?. getLabel ( ) ) . withContext ( 'active item label' ) . toBe ( 'one' ) ;
177
+ expect ( keyManager . getActiveItem ( ) ?. getLabel ( ) )
178
+ . withContext ( 'active item label' )
179
+ . toBe ( 'one' ) ;
176
180
} ) ;
177
181
178
182
describe ( 'Key events' , ( ) => {
179
- it ( 'should emit tabOut when the tab key is pressed' , ( ) => {
183
+ it ( 'should emit tabOut when tab key is pressed' , ( ) => {
180
184
const spy = jasmine . createSpy ( 'tabOut spy' ) ;
181
185
keyManager . tabOut . pipe ( take ( 1 ) ) . subscribe ( spy ) ;
182
186
keyManager . onKeydown ( fakeKeyEvents . tab ) ;
0 commit comments