[libvirt] [PATCH v5 7/9] Add a test case to verify TLS arguments are parsed correctly for a VxHS disk

John Ferlan jferlan at redhat.com
Wed Aug 30 15:20:17 UTC 2017



On 08/29/2017 02:39 AM, Ashish Mittal wrote:
> Test case verifies that XML is generated correctly for a VxHS disk
> having TLS enabled.
> 
> Signed-off-by: Ashish Mittal <Ashish.Mittal at veritas.com>
> ---
>  tests/virstoragetest.c | 11 +++++++++++
>  1 file changed, 11 insertions(+)
> 
> diff --git a/tests/virstoragetest.c b/tests/virstoragetest.c
> index f8444e1..92328ea 100644
> --- a/tests/virstoragetest.c
> +++ b/tests/virstoragetest.c
> @@ -1595,6 +1595,17 @@ mymain(void)
>                         "<source protocol='vxhs' name='c6718f6b-0401-441d-a8c3-1f0064d75ee0'>\n"
>                         "  <host name='example.com' port='1234'/>\n"
>                         "</source>\n");
> +    TEST_BACKING_PARSE("json:{\"file\":{\"driver\":\"vxhs\","
> +                                       "\"vdisk-id\":\"c6718f6b-0401-441d-a8c3-1f0064d75ee0\","
> +                                       "\"server\": { \"host\":\"example.com\","
> +                                                      "\"port\":\"1234\""

Similar to previous alter to have "type":"tcp" and use 9999 for port.

Although this does work as is.

John

> +                                                   "},"
> +                                       "\"tls\":\"yes\""
> +                                      "}"
> +                            "}",
> +                       "<source protocol='vxhs' name='c6718f6b-0401-441d-a8c3-1f0064d75ee0' tls='yes'>\n"
> +                       "  <host name='example.com' port='1234'/>\n"
> +                       "</source>\n");
>  #endif /* WITH_YAJL */
>  
>   cleanup:
> 




More information about the libvir-list mailing list