feat(platform): expose amap server readiness
This commit is contained in:
@@ -898,6 +898,7 @@ func TestHandlerOpsHealthIncludesVehicleServiceRuntime(t *testing.T) {
|
||||
handler := NewHandler(NewServiceWithRuntime(NewMockStore(), RuntimeInfo{
|
||||
RequestTimeoutMs: 1500,
|
||||
AMapWebJSConfigured: true,
|
||||
AMapAPIConfigured: true,
|
||||
AMapSecurityProxyEnabled: true,
|
||||
AMapSecurityCodeExposed: false,
|
||||
AMapSecurityServiceHost: "/_AMapService",
|
||||
@@ -921,6 +922,9 @@ func TestHandlerOpsHealthIncludesVehicleServiceRuntime(t *testing.T) {
|
||||
if !body.Data.Runtime.AMapWebJSConfigured || !body.Data.Runtime.AMapSecurityProxyEnabled {
|
||||
t.Fatalf("ops health should expose AMap runtime readiness, got %+v body=%s", body.Data.Runtime, rec.Body.String())
|
||||
}
|
||||
if !body.Data.Runtime.AMapAPIConfigured {
|
||||
t.Fatalf("ops health should expose server-side AMap API readiness, got %+v body=%s", body.Data.Runtime, rec.Body.String())
|
||||
}
|
||||
if body.Data.Runtime.AMapSecurityCodeExposed {
|
||||
t.Fatalf("ops health should show that AMap security code is not exposed when proxy is enabled: %+v", body.Data.Runtime)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user