Skip to content

Commit 934eb94

Browse files
committed
remove prefix
1 parent 3ad03a5 commit 934eb94

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

lib/propolis/src/lib.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ pub fn version() -> &'static str {
4545
.and_then(|branch| Some((branch, option_env!("VERGEN_GIT_SHA")?)))
4646
.and_then(|(branch, sha)| Some((branch, sha, option_env!("VERGEN_GIT_COMMIT_COUNT")?)));
4747

48-
let mut version = format!("Propolis v{}", env!("CARGO_PKG_VERSION"));
48+
let mut version = format!("v{}", env!("CARGO_PKG_VERSION"));
4949
if let Some((branch, sha, commit)) = git {
5050
write!(version, "-{commit} ({sha}) {branch}, ")
5151
.expect("writing to a string never fails");
@@ -74,7 +74,8 @@ mod tests {
7474
#[test]
7575
fn print_version() {
7676
let v = version();
77-
eprintln!("version: {v}");
78-
assert!(v.starts_with("Propolis v"));
77+
eprintln!("propolis {v}");
78+
assert!(version.contains(env!("CARGO_PKG_VERSION")));
79+
assert!(version.contains("Bhyve API"));
7980
}
8081
}

0 commit comments

Comments
 (0)