File tree Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Original file line number Diff line number Diff line change @@ -543,6 +543,31 @@ test.describe('$Window Component', () => {
543
543
} ) ;
544
544
} ) ;
545
545
546
+ test . describe ( 'getTitlebarIconSize()' , ( ) => {
547
+ test ( 'should return the icon size used in the titlebar' , async ( { page } ) => {
548
+ const h$window = await page . evaluateHandle ( ( ) => {
549
+ const $window = $Window ( {
550
+ title : 'Test Window' ,
551
+ icons : {
552
+ 16 : new Text ( '16x16 placeholder' ) ,
553
+ 32 : new Text ( '32x32 placeholder' ) ,
554
+ any : new Text ( 'any size placeholder' ) ,
555
+ } ,
556
+ } ) ;
557
+ return $window ;
558
+ } ) ;
559
+ expect ( await h$window . evaluate ( ( $window ) =>
560
+ $window . getTitlebarIconSize ( )
561
+ ) ) . toBe ( 16 ) ;
562
+ await h$window . evaluate ( ( $window ) => {
563
+ $window . setTitlebarIconSize ( 48 ) ;
564
+ } ) ;
565
+ expect ( await h$window . evaluate ( ( $window ) =>
566
+ $window . getTitlebarIconSize ( )
567
+ ) ) . toBe ( 48 ) ;
568
+ } ) ;
569
+ } ) ;
570
+
546
571
test . describe ( 'setMenuBar()' , ( ) => {
547
572
test ( 'should add menu bar, which is hidden when minimized' , async ( { page } ) => {
548
573
const h$window = await page . evaluateHandle ( ( ) => {
You can’t perform that action at this time.
0 commit comments