Skip to content

Commit 4052345

Browse files
committed
more
Signed-off-by: Takeshi Yoneda <[email protected]>
1 parent 3b34681 commit 4052345

File tree

5 files changed

+9
-8
lines changed

5 files changed

+9
-8
lines changed

.envoy-version

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
1.36

.github/workflows/build_and_test.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,8 +167,6 @@ jobs:
167167
TEST_SAMBANOVA_API_KEY: ${{ secrets.ENVOY_AI_GATEWAY_SAMBANOVA_API_KEY }}
168168
TEST_DEEPINFRA_API_KEY: ${{ secrets.ENVOY_AI_GATEWAY_DEEPINFRA_API_KEY }}
169169
TEST_GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
170-
# This will be picked up by func-e to run the specified Envoy version.
171-
ENVOY_VERSION: 1.36.0
172170
run: make test-extproc
173171

174172
test_e2e:

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ test-crdcel: apigen ## Run the integration tests of CEL validation in CRD defini
156156
test-extproc: build.extproc ## Run the integration tests for extproc without controller or k8s at all.
157157
@$(MAKE) build.testupstream CMD_PATH_PREFIX=tests/internal/testupstreamlib
158158
@echo "Ensure func-e is built and Envoy is installed"
159-
@@$(GO_TOOL) func-e run --help >/dev/null 2>&1
159+
@@$(GO_TOOL) func-e run --version >/dev/null 2>&1
160160
@echo "Run ExtProc test"
161161
@EXTPROC_BIN=$(OUTPUT_DIR)/extproc-$(shell go env GOOS)-$(shell go env GOARCH) go test ./tests/extproc/... $(GO_TEST_E2E_ARGS)
162162

tests/extproc/extproc_test.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,7 @@ var (
5959
Region: "gcp-region",
6060
ProjectName: "gcp-project-name",
6161
}}}
62-
// This always failing backend is configured to have AWS Bedrock schema so that
63-
// we can test that the extproc can fallback to the different schema. E.g. Primary AWS and then OpenAI.
64-
alwaysFailingBackend = filterapi.Backend{Name: "always-failing-backend", Schema: awsBedrockSchema}
62+
alwaysFailingBackend = filterapi.Backend{Name: "always-failing-backend", Schema: openAISchema}
6563

6664
// envoyConfig is the embedded Envoy configuration template.
6765
//

tests/internal/testenvironment/test_environment.go

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import (
1313
"net"
1414
"os"
1515
"os/exec"
16+
"path/filepath"
1617
"runtime"
1718
"strconv"
1819
"strings"
@@ -275,8 +276,11 @@ func requireEnvoy(t testing.TB,
275276
// Add debug logging for http.
276277
"--component-log-level", "http:debug",
277278
)
278-
// Use the existing environment for func-e.
279-
cmd.Env = os.Environ()
279+
// func-e will use the version specified in the project root's .envoy-version file.
280+
cmd.Dir = internaltesting.FindProjectRoot()
281+
version, err := os.ReadFile(filepath.Join(cmd.Dir, ".envoy-version"))
282+
require.NoError(t, err)
283+
t.Logf("Starting Envoy version %s", strings.TrimSpace(string(version)))
280284
cmd.WaitDelay = 3 * time.Second // auto-kill after 3 seconds.
281285
t.Cleanup(func() {
282286
defer cancel()

0 commit comments

Comments
 (0)