blob: 90c395a82b049e2ed759fd48870e45c246920b63 [file] [log] [blame]
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# This file is used to show how to write configuration files and can be used to test.
setup:
env: compose
file: docker-compose.yml
timeout: 1200
init-system-environment: ../../base/env
steps:
- name: install yq
command: bash test/e2e/base/scripts/prepare/setup-e2e-shell/install.sh yq
- name: install swctl
command: bash test/e2e/base/scripts/prepare/setup-e2e-shell/install.sh swctl
cleanup:
# always never success failure
on: always
trigger:
action: http
interval: 3s
times: 5
url: http://${consumer_host}:${consumer_9090}/info
method: POST
verify:
# verify with retry strategy
retry:
# max retry count
count: 20
# the interval between two retries, in millisecond.
interval: 10s
cases:
# basic check: service list
- query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql service ls
expected: expected/service.yml
# basic check: service instance list
- query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql instance list --service-name test-app-v1
expected: expected/service-instance.yml
# als: logs list
- query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql logs list --service-name test-app-v1 |yq e 'del(.. | select(has("content")).content)' -
expected: expected/logs-list.yml
# metrics: envoy metrics
- query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics linear --name envoy_worker_threads --service-name istio-dp::test-app-v1 --instance-name service-instance-name-v1|yq e 'to_entries' -
expected: expected/metrics-has-value.yml