jobs:
- job: "build_linux_amd64"
  pool:
    vmImage: 'ubuntu-20.04'
  steps:
  - template: steps-build-docker-image.yaml
    parameters:
      language: c

- job: "test_linux_amd64"
  pool:
      vmImage: 'ubuntu-20.04'
  dependsOn:
    - "build_linux_amd64"
  strategy:
    matrix:
      c_mqtt_iothub_module:     { suite: c_mqtt_iothub_moduled }
      c_mqtt_edgehub_module:    { suite: c_mqtt_edgehub_module }
      c_mqttws_iothub_module:   { suite: c_mqttws_iothub_module }
      c_mqttws_edgehub_module:  { suite: c_mqttws_edgehub_module }
      c_amqp_iothub_module:     { suite: c_amqp_iothub_module }
      c_amqpws_iothub_module:   { suite: c_amqpws_iothub_module }

  steps:
  - template: steps-deploy-and-run-pytest.yaml
    parameters:
      forced_image: $(Horton.ForcedImage)
      suite: $(suite)

