1
1
mirror of https://github.com/wez/wezterm.git synced 2024-12-29 16:42:13 +03:00

gui: flesh out test case for wsl -l -v

closes: https://github.com/wez/wezterm/issues/1462
This commit is contained in:
Wez Furlong 2021-12-27 10:38:10 -07:00
parent 780756bea8
commit 8c7072c5ef
2 changed files with 39 additions and 9 deletions

View File

@ -62,6 +62,7 @@ As features stabilize some brief notes about them will accumulate here.
* Colors were too intense due to over gamma correction [#1025](https://github.com/wez/wezterm/issues/1025) * Colors were too intense due to over gamma correction [#1025](https://github.com/wez/wezterm/issues/1025)
* Mesa and EGL colors were too dim due to under gamma correction [#1373](https://github.com/wez/wezterm/issues/1373) * Mesa and EGL colors were too dim due to under gamma correction [#1373](https://github.com/wez/wezterm/issues/1373)
* `wezterm ssh` no longer tries to use `default_prog` or `default_cwd` when spawning additional panes on the remote host [#1456](https://github.com/wez/wezterm/issues/1456) * `wezterm ssh` no longer tries to use `default_prog` or `default_cwd` when spawning additional panes on the remote host [#1456](https://github.com/wez/wezterm/issues/1456)
* Launcher menu WSL items now launch correctly on non-US versions of Windows [#1462](https://github.com/wez/wezterm/issues/1462)
### 20211205-192649-672c1cc1 ### 20211205-192649-672c1cc1

View File

@ -137,18 +137,47 @@ fn parse_wsl_distro_list(output: &str) -> Vec<WslDistro> {
#[cfg(test)] #[cfg(test)]
#[test] #[test]
fn test_parse_wsl_distro_list() { fn test_parse_wsl_distro_list() {
let data = " NAME STATE VERSION\n\ let data = " NAME STATE VERSION
* Ubuntu-18.04 Running 1\n * Arch Running 2
"; docker-desktop-data Stopped 2
docker-desktop Stopped 2
Ubuntu Stopped 2
nvim Stopped 2";
assert_eq!( assert_eq!(
parse_wsl_distro_list(data), parse_wsl_distro_list(data),
vec![WslDistro { vec![
name: "Ubuntu-18.04".to_string(), WslDistro {
state: "Running".to_string(), name: "Arch".to_string(),
version: "1".to_string(), state: "Running".to_string(),
is_default: true version: "2".to_string(),
}] is_default: true
},
WslDistro {
name: "docker-desktop-data".to_string(),
state: "Stopped".to_string(),
version: "2".to_string(),
is_default: false
},
WslDistro {
name: "docker-desktop".to_string(),
state: "Stopped".to_string(),
version: "2".to_string(),
is_default: false
},
WslDistro {
name: "Ubuntu".to_string(),
state: "Stopped".to_string(),
version: "2".to_string(),
is_default: false
},
WslDistro {
name: "nvim".to_string(),
state: "Stopped".to_string(),
version: "2".to_string(),
is_default: false
},
]
); );
} }