P0 fixes: - ModelError.Is(): use exact matching instead of substring contains() - shouldClearStickySession: add context param for cancellation/tracing P1 fixes: - TODO stubs: return 501 Not Implemented errors - validateInstanceSignature: deduplicate to shared validateCodeSignature() - Error messages: standardize to English only - http.go: remove pseudo if-else with duplicate branches
19 lines
430 B
Go
19 lines
430 B
Go
package geminicli
|
|
|
|
import "testing"
|
|
|
|
func TestDriveStorageInfo(t *testing.T) {
|
|
// 测试 DriveStorageInfo 结构体
|
|
info := &DriveStorageInfo{
|
|
Limit: 100 * 1024 * 1024 * 1024, // 100GB
|
|
Usage: 50 * 1024 * 1024 * 1024, // 50GB
|
|
}
|
|
|
|
if info.Limit != 100*1024*1024*1024 {
|
|
t.Errorf("Expected limit 100GB, got %d", info.Limit)
|
|
}
|
|
if info.Usage != 50*1024*1024*1024 {
|
|
t.Errorf("Expected usage 50GB, got %d", info.Usage)
|
|
}
|
|
}
|