# Copyright The OpenTelemetry Authors # SPDX-License-Identifier: Apache-2.0 type: Test spec: id: shipping-quote name: 'Shipping: Quote' description: Quote delivery for one order trigger: type: grpc grpc: protobufFile: ../../../pb/demo.proto address: ${env:SHIPPING_SERVICE_ADDR} method: oteldemo.ShippingService.GetQuote request: |- { "address": { "streetAddress": "One Microsoft Way", "city": "Redmond", "state": "Washington", "country": "United States", "zipCode": "98052" }, "items": [ { "productId": "66VCHSJNUP", "quantity": 2 } ] } specs: - name: It called GetQuote correctly selector: span[tracetest.span.type="rpc" name="oteldemo.ShippingService/GetQuote" rpc.system="grpc"] assertions: - attr:rpc.grpc.status_code = 0 - name: It returned a valid quote selector: span[tracetest.span.type="general" name="Tracetest trigger"] assertions: - attr:tracetest.response.body | json_path '$.costUsd.currencyCode' = "USD" - attr:tracetest.response.body | json_path '$.costUsd.units' = 17 - attr:tracetest.response.body | json_path '$.costUsd.nanos' = 800000000