test(ai-proxy): expand wasm integration tests, coverage, and provider matrix (#3790)

Signed-off-by: jingze <daijingze.djz@alibaba-inc.com>
This commit is contained in:
Jingze
2026-05-12 10:20:08 +08:00
committed by GitHub
parent 678ea5660e
commit 1c4fe1c9f9
25 changed files with 2076 additions and 0 deletions

View File

@@ -1,11 +1,19 @@
package test
import (
"encoding/json"
"testing"
"github.com/alibaba/higress/plugins/wasm-go/extensions/ai-proxy/util"
)
// LegacyProviderPluginJSON builds the top-level plugin JSON with a single legacy "provider"
// object, matching historical wasm integration tests (see test/openai.go).
func LegacyProviderPluginJSON(provider map[string]interface{}) json.RawMessage {
data, _ := json.Marshal(map[string]interface{}{"provider": provider})
return json.RawMessage(data)
}
func RunMapRequestPathByCapabilityTests(t *testing.T) {
testCases := []struct {
name string