Validate get keypair attributes of Nova V2/V3 API

This patch adds the JSON Schema for response of Nova V2 & V3 GET
keypair API and validate the response with added JSON Schema to
block the backward incompatibility change in the future.

The response body of V2 GET keypair API is below:

{
    "keypair": {
        "public_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDnPe3MJhE
                      wcQNGZpYRaGYTwY9D9L3pr1c+eqJIP99mtrUuqTEp3/YPiAz
                      L0Dem/32WWPOV4DEc27NBMxrpOi9JJBssDq+6UdK5hMIwrZ/
                      6dZt+CPz+76LwxnR1vilVFocis+OC9ddntazV1wrAWGyYL9a
                      83vwcuTV01FJzSNlYV4hni2vxcgQPkbgt+ldYoTmBS9X3W5Qy
                      NrzuG53zHjkYjmz3tjiadZwgffDvjT3SBYWU3kBGy6gxIs5f/
                      wIvZUSUXGorOJNUw6FubMj4sLfE4cbHS6W72xs6bmEhqxyjSL
                      QK5fuHE1MgCCDPTd0vqXdbLnCZr6+l0HLI8lpDhd
                      Generated by Nova\n",
        "name": "test_key",
        "fingerprint": "52:53:dd:89:6a:73:c6:18:87:4b:1e:c1:4c:b8:
                       c3:c9",
        "user_id": "93d29478a2454f418e0b835b8439aa90",
        "deleted": false,
        "created_at": "2014-03-17T06:49:35.000000",
        "updated_at": null,
        "deleted_at": null,
        "id": 1
    }
}

The response body of V3 GET keypair API is below:

{
    "keypair": {
        "public_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDnPe3MJhE
                      wcQNGZpYRaGYTwY9D9L3pr1c+eqJIP99mtrUuqTEp3/YPiAz
                      pL0Dem/32WWPOV4DEc27NBMxrpOi9JJBssDq+6UdK5hMIwrZ/
                      6dZt+CPz+76LwxnR1vilVFocis+OC9ddntazV1wrAWGyYL9a
                      83vwcuTV01FJzSNlYV4hni2vxcgQPkbgt+ldYoTmBS9X3W5Qy
                      /NrzuG53zHjkYjmz3tjiadZwgffDvjT3SBYWU3kBGy6gxIs5f
                      /wIvZUSUXGorOJNUw6FubMj4sLfE4cbHS6W72xs6bmEhqxyjS
                      LQK5fuHE1MgCCDPTd0vqXdbLnCZr6+l0HLI8lpDhd
                      Generated by Nova\n",
        "name": "test_key",
        "fingerprint": "52:53:dd:89:6a:73:c6:18:87:4b:1e:c1:4c:b8:
                       c3:c9"
    }
}

Partially implements blueprint nova-api-attribute-test

Change-Id: Ie65776ec5f6a42df89c27d868b43c4ce105dd09b
4 files changed