name: Check unregistered node
testcases:
- name: get_login_token
  steps:
  - type: get_login_token

- name: check_unregistered_node
  steps:
  - type: http
    method: GET
    url: '{{.pfserver_webadmin_url}}/api/v1/node/{{.node01_ens7_mac_address_url_encoded}}'
    ignore_verify_ssl: true
    headers:
      "Authorization": "{{.get_login_token.result.token}}"
      "Content-Type": "application/json"
    assertions:
      - result.statuscode ShouldEqual 200
      - result.bodyjson.item.autoreg ShouldEqual no
      - result.bodyjson.item.status ShouldEqual unreg
      - result.bodyjson.item.regdate ShouldEqual "0000-00-00 00:00:00"
      - result.bodyjson.item.unregdate ShouldEqual "0000-00-00 00:00:00"

