@@ -230,16 +230,22 @@ init_per_group(Group, Config) when Group =:= tty_unicode;
230230 os :getenv (" LC_ALL" ,
231231 os :getenv (" LC_CTYPE" ,
232232 os :getenv (" LANG" ," en_US.UTF-8" )))," ." ),
233- case Group of
234- tty_unicode ->
235- [{encoding , unicode },{env ,[{" LC_ALL" ,Lang ++ " .UTF-8" }]}|Config ];
236- tty_latin1 ->
233+ % % Version 3.3 introduced new widths for unicode characters which seem to be different from running in non tmux shell
234+ % % An option is added in 3.6 where a unicode character width can be overridden, skip unicode for 3.3-3.5a
235+ TmuxVersion = string :chomp (os :cmd (" tmux -V" )),
236+ Skip = [] =/= [true || Major <- [" 3.3" ," 3.4" ," 3.5" ], Minor <- [" " ," a" ], TmuxVersion =:= (Major ++ Minor )],
237+ case {Group ,Skip } of
238+ {tty_latin1 ,_ } ->
237239 % [{encoding, latin1},{env,[{"LC_ALL",Lang++".ISO-8859-1"}]}|Config],
238240 {skip , " latin1 tests not implemented yet" };
239- ssh_unicode ->
241+ {ssh_latin1 ,_ } ->
242+ {skip , " latin1 tests not implemented yet" };
243+ {_ , true } ->
244+ {skip , " tmux version incompatible with unicode tests" };
245+ {tty_unicode ,_ } ->
240246 [{encoding , unicode },{env ,[{" LC_ALL" ,Lang ++ " .UTF-8" }]}|Config ];
241- ssh_latin1 ->
242- { skip , " latin1 tests not implemented yet " }
247+ { ssh_unicode , _ } ->
248+ [{ encoding , unicode },{ env ,[{ " LC_ALL " , Lang ++ " .UTF-8 " }]}| Config ]
243249 end ;
244250init_per_group (sh_custom , Config ) ->
245251 % % Ensure that ERL_AFLAGS will not override the value of the shell_history variable.
0 commit comments