Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions crates/genie-core/tests/tool_dispatch_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,13 @@ fn core_binary_builds() {
);
}

/// Verify release binary is under 5 MB.
/// genie-core release-binary size ceiling. Raised from the alpha-era
/// 5.0 MB budget after legitimate growth from the runtime backend,
/// voice, runtime mode, and concurrent server work. Keep it tight enough
/// that another large dependency or module forces a deliberate decision.
const RELEASE_BINARY_SIZE_BUDGET_MB: f64 = 6.0;

/// Verify release binary stays within the release size budget.
#[test]
fn binary_size_budget() {
let output = build_release_genie_core();
Expand All @@ -31,7 +37,12 @@ fn binary_size_budget() {
let size = std::fs::metadata(&path).unwrap().len();
let size_mb = size as f64 / 1_048_576.0;
println!("genie-core: {:.2} MB", size_mb);
assert!(size_mb < 5.0, "{:.1} MB exceeds 5 MB budget", size_mb);
assert!(
size_mb < RELEASE_BINARY_SIZE_BUDGET_MB,
"{:.1} MB exceeds {:.1} MB budget",
size_mb,
RELEASE_BINARY_SIZE_BUDGET_MB
);
}
}

Expand Down
Loading