HAALCENTRAAL English translation
BRP API / Personen / Features / dan-stap-definities-nationaliteit

Nationaliteit Then step definitions

#language: en

@stap-documentatie
Feature: Nationaliteit Then step definitions

  Scenario Outline: Then the response has a person with a 'nationaliteit' with (only) the following data
    Given the response body equals
    """
    {
      "personen": [
        {
          "nationaliteiten": [
            {
              "aanduidingBijzonderNederlanderschap": "V"
            }
          ]
        }
      ]
    }
    """
    Then <stap definitie met hetzelfde gedrag>
    | naam                                | waarde |
    | aanduidingBijzonderNederlanderschap | V      |

    Examples:
    | stap definitie met hetzelfde gedrag                                                   |
    | heeft de response een persoon met een 'nationaliteit' met de volgende gegevens        |
    | heeft de response een persoon met een 'nationaliteit' met alleen de volgende gegevens |

  Scenario: Then the response has a person without nationalities
    Given the response body equals
    """
    {
      "personen": [
        {
          "nationaliteiten": []
        }
      ]
    }
    """
    Then the response has a person without nationalities

  Scenario: Then the person has a 'nationaliteit' with (only) the following data
    Given the response body equals
    """
    {
      "personen": [
        {
          "burgerservicenummer": "000000012",
          "nationaliteiten": [
            {
              "aanduidingBijzonderNederlanderschap": "V"
            }
          ]
        }
      ]
    }
    """
    Then the response has a person with the following data
    | burgerservicenummer |
    | 000000012           |
    Then <stap definitie met hetzelfde gedrag>
    | naam                                | waarde |
    | aanduidingBijzonderNederlanderschap | V      |

    Examples:
    | stap definitie met hetzelfde gedrag                                  |
    | heeft de persoon een 'nationaliteit' met de volgende gegevens        |
    | heeft de persoon een 'nationaliteit' met alleen de volgende gegevens |

  Scenario: Then the person has no nationalities
    Given the response body equals
    """
    {
      "personen": [
        {
          "burgerservicenummer": "000000012",
          "nationaliteiten": []
        }
      ]
    }
    """
    Then the response has a person with the following data
    | naam                | waarde    |
    | burgerservicenummer | 000000012 |
    And the person has no nationalities