🐛 fix: add test for asset name format and bump to 0.5.2
All checks were successful
continuous-integration/drone/tag Build is passing
All checks were successful
continuous-integration/drone/tag Build is passing
Adds a unit test that asserts detect_arch returns names prefixed with 'tmuxido-' and suffixed with '-linux', matching what CI uploads.
This commit is contained in:
parent
36aaa65945
commit
2b1773375a
@ -4,6 +4,11 @@ All notable changes to this project will be documented in this file.
|
|||||||
|
|
||||||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
||||||
|
|
||||||
|
## [0.5.2] - 2026-03-01
|
||||||
|
|
||||||
|
### Added
|
||||||
|
- Test for `detect_arch` asserting asset name follows `tmuxido-{arch}-linux` format
|
||||||
|
|
||||||
## [0.5.1] - 2026-03-01
|
## [0.5.1] - 2026-03-01
|
||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
|
|||||||
2
Cargo.lock
generated
2
Cargo.lock
generated
@ -864,7 +864,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "tmuxido"
|
name = "tmuxido"
|
||||||
version = "0.5.1"
|
version = "0.5.2"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"clap",
|
"clap",
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "tmuxido"
|
name = "tmuxido"
|
||||||
version = "0.5.1"
|
version = "0.5.2"
|
||||||
edition = "2024"
|
edition = "2024"
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
|
|||||||
@ -198,6 +198,19 @@ mod tests {
|
|||||||
assert!(version.contains('.'));
|
assert!(version.contains('.'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn should_prefix_arch_asset_with_tmuxido() {
|
||||||
|
let arch = detect_arch().expect("should detect supported arch");
|
||||||
|
assert!(
|
||||||
|
arch.starts_with("tmuxido-"),
|
||||||
|
"asset name must start with 'tmuxido-', got: {arch}"
|
||||||
|
);
|
||||||
|
assert!(
|
||||||
|
arch.ends_with("-linux"),
|
||||||
|
"asset name must end with '-linux', got: {arch}"
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn should_compare_versions_correctly() {
|
fn should_compare_versions_correctly() {
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user