Fusion copies prep icon and version info via go-winres; optional Garble obfuscation, Authenticode signing, and dry-run size estimates. Forge Simple mode with smart defaults; fleet roster gets compact expandable cards, filters, bulk commands, per-agent notes/tags, and typed WebSocket payloads.
30 lines
731 B
Go
30 lines
731 B
Go
package builder
|
|
|
|
import "testing"
|
|
|
|
func TestEstimateFusionBuildTotals(t *testing.T) {
|
|
h := &Handler{
|
|
dataDir: t.TempDir(),
|
|
projectRoot: t.TempDir(),
|
|
}
|
|
req := &BuildRequest{
|
|
FusionEnabled: true,
|
|
FusionOutputName: "MyApp.exe",
|
|
OutputDir: "exports",
|
|
Obfuscate: true,
|
|
}
|
|
got := h.estimateFusionBuild(req, "", 5*1024*1024, "MyApp.exe")
|
|
if got.PrepBytes != 5*1024*1024 {
|
|
t.Fatalf("prep bytes: got %d", got.PrepBytes)
|
|
}
|
|
if got.EstimatedTotalBytes <= got.PrepBytes {
|
|
t.Fatalf("total should exceed prep: %d", got.EstimatedTotalBytes)
|
|
}
|
|
if got.OutputFileName != "MyApp.exe" {
|
|
t.Fatalf("output name: %s", got.OutputFileName)
|
|
}
|
|
if got.ExportPath == "" {
|
|
t.Fatal("expected export path")
|
|
}
|
|
}
|