@@ -443,6 +443,7 @@ class CLILoadFixture(t.NamedTuple):
443443    test_id : str 
444444    cli_args : t .List [t .Union [str , t .List [str ]]]
445445    config_paths : t .List [str ]
446+     session_names : t .List [str ]
446447    expected_exit_code : int 
447448    expected_in_out : "ExpectedOutput"  =  None 
448449    expected_not_in_out : "ExpectedOutput"  =  None 
@@ -455,6 +456,7 @@ class CLILoadFixture(t.NamedTuple):
455456        test_id = "dir-relative-dot-samedir" ,
456457        cli_args = ["load" , "." ],
457458        config_paths = ["{tmp_path}/.tmuxp.yaml" ],
459+         session_names = ["my_config" ],
458460        expected_exit_code = 0 ,
459461        expected_in_out = None ,
460462        expected_not_in_out = None ,
@@ -463,6 +465,7 @@ class CLILoadFixture(t.NamedTuple):
463465        test_id = "dir-relative-dot-slash-samedir" ,
464466        cli_args = ["load" , "./" ],
465467        config_paths = ["{tmp_path}/.tmuxp.yaml" ],
468+         session_names = ["my_config" ],
466469        expected_exit_code = 0 ,
467470        expected_in_out = None ,
468471        expected_not_in_out = None ,
@@ -471,6 +474,7 @@ class CLILoadFixture(t.NamedTuple):
471474        test_id = "dir-relative-file-samedir" ,
472475        cli_args = ["load" , "./.tmuxp.yaml" ],
473476        config_paths = ["{tmp_path}/.tmuxp.yaml" ],
477+         session_names = ["my_config" ],
474478        expected_exit_code = 0 ,
475479        expected_in_out = None ,
476480        expected_not_in_out = None ,
@@ -479,6 +483,7 @@ class CLILoadFixture(t.NamedTuple):
479483        test_id = "filename-relative-file-samedir" ,
480484        cli_args = ["load" , "./my_config.yaml" ],
481485        config_paths = ["{tmp_path}/my_config.yaml" ],
486+         session_names = ["my_config" ],
482487        expected_exit_code = 0 ,
483488        expected_in_out = None ,
484489        expected_not_in_out = None ,
@@ -487,6 +492,7 @@ class CLILoadFixture(t.NamedTuple):
487492        test_id = "configdir-session-name" ,
488493        cli_args = ["load" , "my_config" ],
489494        config_paths = ["{TMUXP_CONFIGDIR}/my_config.yaml" ],
495+         session_names = ["my_config" ],
490496        expected_exit_code = 0 ,
491497        expected_in_out = None ,
492498        expected_not_in_out = None ,
@@ -495,6 +501,7 @@ class CLILoadFixture(t.NamedTuple):
495501        test_id = "configdir-absolute" ,
496502        cli_args = ["load" , "~/.config/tmuxp/my_config.yaml" ],
497503        config_paths = ["{TMUXP_CONFIGDIR}/my_config.yaml" ],
504+         session_names = ["my_config" ],
498505        expected_exit_code = 0 ,
499506        expected_in_out = None ,
500507        expected_not_in_out = None ,
@@ -509,6 +516,7 @@ class CLILoadFixture(t.NamedTuple):
509516            "{TMUXP_CONFIGDIR}/my_config.yaml" ,
510517            "{TMUXP_CONFIGDIR}/second_config.yaml" ,
511518        ],
519+         session_names = ["my_config" , "second_config" ],
512520        expected_exit_code = 0 ,
513521        expected_in_out = None ,
514522        expected_not_in_out = None ,
@@ -532,6 +540,7 @@ def test_load(
532540    test_id : str ,
533541    cli_args : t .List [str ],
534542    config_paths : t .List [str ],
543+     session_names : t .List [str ],
535544    expected_exit_code : int ,
536545    expected_in_out : "ExpectedOutput" ,
537546    expected_not_in_out : "ExpectedOutput" ,
@@ -541,7 +550,7 @@ def test_load(
541550    assert  server .socket_name  is  not None 
542551
543552    monkeypatch .chdir (tmp_path )
544-     for  config_path  in  config_paths :
553+     for  session_name ,  config_path  in  zip ( session_names ,  config_paths ) :
545554        tmuxp_config  =  pathlib .Path (
546555            config_path .format (tmp_path = tmp_path , TMUXP_CONFIGDIR = tmuxp_configdir )
547556        )
@@ -553,7 +562,7 @@ def test_load(
553562          panes: 
554563          - 
555564        """ .format (
556-                 session_name = pathlib . Path ( config_path ). name . replace ( "." ,  "" ) 
565+                 session_name = session_name 
557566            ),
558567            encoding = "utf-8" ,
559568        )
@@ -578,6 +587,9 @@ def test_load(
578587        for  needle  in  expected_not_in_out :
579588            assert  needle  not  in output 
580589
590+     for  session_name  in  session_names :
591+         assert  server .has_session (session_name )
592+ 
581593
582594def  test_regression_00132_session_name_with_dots (
583595    tmp_path : pathlib .Path ,
0 commit comments