HAALCENTRAAL English translation
BRP API / Personen / Features / onbekendwaardes

As a user of the API I do not want to receive unknown values within adres

# language: en

Feature: As a user of the API I do not want to receive unknown values within adres
  so that I do not have to interpret it and do not have to write code to handle this situation

  Where specific values are reserved in the registry for an unknown value, these values are not passed on in the API.
  Where an element in the registry has a default value, meaning that the value is unknown, the corresponding field is not included in the response.

Rule: Not supplying the default/unknown value of an adres field
  This concerns the following properties and default values of the person:
  | property                                   | standaardwaarde  |
  | ------------------------------------------ | ---------------- |
  | straatnaam (11.10)                         | .                |
  | huisnummer (11.20)                         | 0                |
  | woonplaats (11.70)                         | .                |
  | identificatiecode nummeraanduiding (11.90) | 0000000000000000 |
  | identificatiecode verblijfplaats (11.80)   | 0000000000000000 |

  Scenario: unknown value "." for straatnaam
    Given the person with citizen service number '000000164' has the following 'verblijfplaats' data
    | naam                  | waarde |
    | functie adres (10.10) | W      |
    And the 'verblijfplaats' has the following 'adres' data
    | naam                 | waarde |
    | gemeentecode (92.10) | 0518   |
    | straatnaam (11.10)   | .      |
    | huisnummer (11.20)   | 1      |
    When persons are searched with the following parameters
    | naam                | waarde                                       |
    | type                | RaadpleegMetBurgerservicenummer              |
    | burgerservicenummer | 000000164                                    |
    | fields              | verblijfplaats.verblijfadres.korteStraatnaam |
    Then the response has a person with the following 'verblijfplaats' data
    | naam | waarde |
    | type | Adres  |
    And the 'verblijfplaats' has no 'verblijfadres' data


  Scenario: unknown value "0" for huisnummer
    Given the person with citizen service number '000000176' has the following 'verblijfplaats' data
    | naam                  | waarde |
    | functie adres (10.10) | W      |
    And the 'verblijfplaats' has the following 'adres' data
    | naam                 | waarde     |
    | gemeentecode (92.10) | 0518       |
    | straatnaam (11.10)   | een straat |
    | huisnummer (11.20)   | 0          |
    When persons are searched with the following parameters
    | naam                | waarde                                  |
    | type                | RaadpleegMetBurgerservicenummer         |
    | burgerservicenummer | 000000176                               |
    | fields              | verblijfplaats.verblijfadres.huisnummer |
    Then the response has a person with the following 'verblijfplaats' data
    | naam | waarde |
    | type | Adres  |
    And the 'verblijfplaats' has no 'verblijfadres' data

  Scenario Outline: unknown value "<waarde>" for <element>
   Given the person with citizen service number '000000188' has the following 'verblijfplaats' data
    | naam                  | waarde |
    | functie adres (10.10) | W      |
    And the 'verblijfplaats' has the following 'adres' data
    | naam                 | waarde     |
    | gemeentecode (92.10) | 0344       |
    | straatnaam (11.10)   | een straat |
    | <element>            | <waarde>   |
    When persons are searched with the following parameters
    | naam                | waarde                          |
    | type                | RaadpleegMetBurgerservicenummer |
    | burgerservicenummer | 000000188                       |
    | fields              | <field>                         |
    Then the response has a person with only the following 'verblijfplaats' data
    | naam | waarde |
    | type | Adres  |

    Examples:
    | field                                           | element                                    | waarde           |
    | verblijfplaats.nummeraanduidingIdentificatie    | identificatiecode nummeraanduiding (11.90) | 0000000000000000 |
    | verblijfplaats.adresseerbaarObjectIdentificatie | identificatiecode verblijfplaats (11.80)   | 0000000000000000 |

  Scenario: unknown value "." for woonplaats (11.70)
   Given the person with citizen service number '000000188' has the following 'verblijfplaats' data
    | naam                  | waarde |
    | functie adres (10.10) | W      |
    And the 'verblijfplaats' has the following 'adres' data
    | naam                 | waarde     |
    | gemeentecode (92.10) | 0344       |
    | straatnaam (11.10)   | een straat |
    | woonplaats (11.70)   | .          |
    When persons are searched with the following parameters
    | naam                | waarde                                  |
    | type                | RaadpleegMetBurgerservicenummer         |
    | burgerservicenummer | 000000188                               |
    | fields              | verblijfplaats.verblijfadres.woonplaats |
    Then the response has a person with only the following 'verblijfplaats' data
    | naam | waarde |
    | type | Adres  |
    And the 'verblijfplaats' has no 'verblijfadres' data

  Scenario: an entirely unknown start date of the address occupancy in verblijfplaats
    Given the person with citizen service number '000000371' has the following 'verblijfplaats' data
    | naam                               | waarde   |
    | functie adres (10.10)              | W        |
    | datum aanvang adreshouding (10.30) | 00000000 |
    And the 'verblijfplaats' has the following 'adres' data
    | naam                 | waarde     |
    | gemeentecode (92.10) | 0344       |
    | straatnaam (11.10)   | een straat |
    When persons are searched with the following parameters
    | naam                | waarde                          |
    | type                | RaadpleegMetBurgerservicenummer |
    | burgerservicenummer | 000000371                       |
    | fields              | verblijfplaats.datumVan         |
    Then the response has a person with only the following 'verblijfplaats' data
    | naam                 | waarde        |
    | type                 | Adres         |
    | datumVan.type        | DatumOnbekend |
    | datumVan.onbekend    | true          |
    | datumVan.langFormaat | onbekend      |