{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://catalog.lintel.tools/schemas/schemastore/behat-yml/latest.json",
  "title": "JSON schema for Behat configuration files",
  "x-lintel": {
    "source": "https://www.schemastore.org/behat.json",
    "sourceSha256": "2dda62597eb626305903b200529abc6693b488347021b0dfef648b094fc42b08",
    "fileMatch": [
      "behat.yml",
      "*.behat.yml"
    ],
    "parsers": [
      "yaml"
    ]
  },
  "type": "object",
  "properties": {
    "default": {
      "$ref": "#/$defs/profile",
      "title": "Default profile"
    },
    "imports": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "uniqueItems": true
    }
  },
  "$defs": {
    "profile": {
      "title": "Profile",
      "type": "object",
      "properties": {
        "autoload": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          }
        },
        "formatters": {
          "title": "How to format tests output",
          "default": "pretty",
          "type": "object",
          "properties": {
            "pretty": {
              "title": "Prints the feature as is",
              "type": "boolean"
            },
            "progress": {
              "title": "Prints one character per step",
              "type": "boolean"
            },
            "junit": {
              "title": "Outputs the failures in JUnit compatible files.",
              "type": "boolean"
            }
          },
          "additionalProperties": false
        },
        "suites": {
          "title": "Test suites",
          "type": "object",
          "additionalProperties": {
            "$ref": "#/$defs/suite"
          }
        },
        "extensions": {
          "title": "Behat extensions",
          "type": "object",
          "additionalProperties": {
            "type": "object"
          }
        }
      }
    },
    "suite": {
      "title": "Test suite",
      "type": "object",
      "properties": {
        "paths": {
          "title": "Paths to execute",
          "type": "array",
          "items": {
            "type": "string"
          },
          "uniqueItems": true
        },
        "contexts": {
          "title": "Suite contexts",
          "type": "array",
          "items": {
            "type": [
              "string",
              "object"
            ]
          },
          "uniqueItems": true
        },
        "filters": {
          "title": "Suite filters",
          "type": "object",
          "properties": {
            "tags": {
              "type": "string"
            },
            "role": {
              "type": "string"
            }
          }
        }
      }
    }
  },
  "additionalProperties": {
    "$ref": "#/$defs/profile",
    "title": "Profile name"
  }
}
