Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[backport/v1.18] ci: Fix broken tests #20754

Merged
merged 3 commits into from
Apr 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .azure-pipelines/pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,7 @@ stages:
- job: test
timeoutInMinutes: 180
pool:
vmImage: "macos-latest"
vmImage: "macos-10.15"
steps:
- script: ./ci/mac_ci_setup.sh
displayName: "Install dependencies"
Expand Down Expand Up @@ -441,7 +441,7 @@ stages:
- job: release
timeoutInMinutes: 120
pool:
vmImage: "windows-latest"
vmImage: "windows-2019"
steps:
- task: Cache@2
inputs:
Expand Down Expand Up @@ -476,7 +476,7 @@ stages:
- job: clang_cl
timeoutInMinutes: 120
pool:
vmImage: "windows-latest"
vmImage: "windows-2019"
steps:
- task: Cache@2
inputs:
Expand Down Expand Up @@ -512,7 +512,7 @@ stages:
dependsOn: ["release"]
timeoutInMinutes: 120
pool:
vmImage: "windows-latest"
vmImage: "windows-2019"
steps:
- task: DownloadBuildArtifacts@0
inputs:
Expand Down
2 changes: 1 addition & 1 deletion ci/docker_ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ for BUILD_TYPE in "${BUILD_TYPES[@]}"; do
build_images "${BUILD_TYPE}" "$image_tag"

if ! is_windows; then
if [[ "$BUILD_TYPE" == "" || "$BUILD_TYPE" == "-alpine" ]]; then
if [[ "$BUILD_TYPE" == "" || "$BUILD_TYPE" == "-alpine" || "$BUILD_TYPE" == "-google-vrp" ]]; then
# verify_examples expects the base and alpine images, and for them to be named `-dev`
dev_image="envoyproxy/envoy${BUILD_TYPE}-dev:latest"
docker tag "$image_tag" "$dev_image"
Expand Down
15 changes: 11 additions & 4 deletions ci/mac_ci_steps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,16 +36,23 @@ BAZEL_BUILD_OPTIONS=(
# is somewhat more deterministic (rather than interleaving the build
# and test steps).

DEFAULT_TEST_TARGETS=(
"//test/integration:integration_test"
"//test/integration:protocol_integration_test"
"//test/integration:tcp_proxy_integration_test"
"//test/integration:extension_discovery_integration_test"
"//test/integration:listener_lds_integration_test")

if [[ $# -gt 0 ]]; then
TEST_TARGETS=$*
TEST_TARGETS=("$@")
else
TEST_TARGETS='//test/integration/...'
TEST_TARGETS=("${DEFAULT_TEST_TARGETS[@]}")
fi

if [[ "$TEST_TARGETS" == "//test/..." || "$TEST_TARGETS" == "//test/integration/..." ]]; then
if [[ "${TEST_TARGETS[*]}" == "${DEFAULT_TEST_TARGETS[*]}" ]]; then
bazel build "${BAZEL_BUILD_OPTIONS[@]}" //source/exe:envoy-static
fi
bazel test "${BAZEL_BUILD_OPTIONS[@]}" "${TEST_TARGETS}"
bazel test "${BAZEL_BUILD_OPTIONS[@]}" "${TEST_TARGETS[@]}"

# Additionally run macOS specific test suites
bazel test "${BAZEL_BUILD_OPTIONS[@]}" //test/common/network:apple_dns_impl_test
5 changes: 4 additions & 1 deletion examples/cache/service.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,10 @@ def get(service_number, response_id):

# response.make_conditional() will change the response to a 304 response
# if a 'if-none-match' header exists in the request and matches the etag
return response.make_conditional(request)
conditional_response = response.make_conditional(request)
# hacky workaround for flask's dodgy header handling
del conditional_response.headers["Date"]
return conditional_response


if __name__ == "__main__":
Expand Down