type: test/samples
schema_version: 1
test:
  suites:
  - name: Multi-Channel Audio Transcription (Cloud Storage)
    cases:

    # This sample should default to using gs://cloud-samples-data/speech/multi.wav
    # with 2 audio channels of data
    - name: speech_transcribe_multichannel_gcs (no arguments)
      spec:
      - call:
          sample: speech_transcribe_multichannel_gcs
      - assert_contains:
        - literal: "Channel tag: 1"
        - literal: "Channel tag: 2"
        - literal: "how are you doing"

    # Confirm that another file can be transcribed (use another 2 channel .wav file)
    - name: speech_transcribe_multichannel_gcs (--storage_uri)
      spec:
      - call:
          sample: speech_transcribe_multichannel_gcs
          params:
            storage_uri:
              literal: "gs://cloud-samples-data/speech/brooklyn_bridge.wav"
      - assert_contains:
        # Only one channel of data is present in brooklyn_bridge.wav
        - literal: "Channel tag:"
        - literal: "how old is the Brooklyn Bridge"
      - assert_not_contains:
        - literal: "how are you doing"
