@@ -441,7 +441,7 @@ def test_load_symlinked_workspace(
441
441
442
442
class CLILoadFixture (t .NamedTuple ):
443
443
test_id : str
444
- cli_args : t .List [str ]
444
+ cli_args : t .List [t . Union [ str , t . List [ str ]] ]
445
445
config_paths : t .List [str ]
446
446
expected_exit_code : int
447
447
expected_in_out : "ExpectedOutput" = None
@@ -499,6 +499,20 @@ class CLILoadFixture(t.NamedTuple):
499
499
expected_in_out = None ,
500
500
expected_not_in_out = None ,
501
501
),
502
+ #
503
+ # Multiple configs
504
+ #
505
+ CLILoadFixture (
506
+ test_id = "configdir-session-name-double" ,
507
+ cli_args = ["load" , "my_config" , "second_config" ],
508
+ config_paths = [
509
+ "{TMUXP_CONFIGDIR}/my_config.yaml" ,
510
+ "{TMUXP_CONFIGDIR}/second_config.yaml" ,
511
+ ],
512
+ expected_exit_code = 0 ,
513
+ expected_in_out = None ,
514
+ expected_not_in_out = None ,
515
+ ),
502
516
]
503
517
504
518
@@ -533,17 +547,19 @@ def test_load(
533
547
)
534
548
tmuxp_config .write_text (
535
549
"""
536
- session_name: test
550
+ session_name: {session_name}
537
551
windows:
538
552
- window_name: test
539
553
panes:
540
554
-
541
- """ ,
555
+ """ .format (
556
+ session_name = pathlib .Path (config_path ).name .replace ("." , "" )
557
+ ),
542
558
encoding = "utf-8" ,
543
559
)
544
560
545
561
try :
546
- cli .cli ([* cli_args , "-d" , "-L" , server .socket_name ])
562
+ cli .cli ([* cli_args , "-d" , "-L" , server .socket_name , "-y" ])
547
563
except SystemExit :
548
564
pass
549
565
0 commit comments