fix: remove doubled -alpha-alpha version suffix
CARGO_PKG_VERSION already contains -alpha from Cargo.toml, so the
format!("{}-alpha", ...) was producing 1.2.0-alpha-alpha. Use the
Cargo version directly.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
b9c9881e4b
commit
3187d1ad28
@ -244,7 +244,7 @@ impl DataModel {
|
|||||||
Self {
|
Self {
|
||||||
server_info: ServerInfo {
|
server_info: ServerInfo {
|
||||||
id: uuid::Uuid::new_v4().to_string(),
|
id: uuid::Uuid::new_v4().to_string(),
|
||||||
version: format!("{}-alpha", env!("CARGO_PKG_VERSION")),
|
version: env!("CARGO_PKG_VERSION").to_string(),
|
||||||
name: Some("Archipelago".to_string()),
|
name: Some("Archipelago".to_string()),
|
||||||
pubkey: String::new(),
|
pubkey: String::new(),
|
||||||
status_info: StatusInfo {
|
status_info: StatusInfo {
|
||||||
|
|||||||
@ -94,8 +94,8 @@ mod tests {
|
|||||||
let sm = StateManager::new();
|
let sm = StateManager::new();
|
||||||
let (data, rev) = sm.get_snapshot().await;
|
let (data, rev) = sm.get_snapshot().await;
|
||||||
assert_eq!(rev, 0);
|
assert_eq!(rev, 0);
|
||||||
// DataModel::new() sets version from CARGO_PKG_VERSION with alpha suffix
|
// DataModel::new() sets version from CARGO_PKG_VERSION
|
||||||
assert_eq!(data.server_info.version, format!("{}-alpha", env!("CARGO_PKG_VERSION")));
|
assert_eq!(data.server_info.version, env!("CARGO_PKG_VERSION"));
|
||||||
assert!(data.package_data.is_empty());
|
assert!(data.package_data.is_empty());
|
||||||
assert!(data.notifications.is_empty());
|
assert!(data.notifications.is_empty());
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user