From ca84f7b582bd159c1ca98e7a1d079dab9e5d3d42 Mon Sep 17 00:00:00 2001 From: Alex Zorin Date: Sat, 2 Aug 2014 12:51:44 +1000 Subject: [PATCH] add TestIntegrationDomainBlockStatsFlags --- integration_test.go | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/integration_test.go b/integration_test.go index 245e45f..0ce3120 100644 --- a/integration_test.go +++ b/integration_test.go @@ -794,3 +794,31 @@ func TestIntergrationListAllNWFilters(t *testing.T) { t.Fatalf("NWFilter %s not found", testNWFilterName) } } + +func TestIntegrationDomainBlockStatsFlags(t *testing.T) { + conn, err := NewVirConnection("lxc:///") + if err != nil { + t.Fatal(err) + } + defer conn.CloseConnection() + + dom, err := defineTestLxcDomain(conn, "") + if err != nil { + t.Fatal(err) + } + defer func() { + dom.Undefine() + dom.Free() + }() + + if err := dom.Create(); err != nil { + t.Fatal(err) + } + defer dom.Destroy() + + // special case, count number of parameters + _, err = dom.BlockStatsFlags("", nil, 0, 0) + if err != nil { + t.Fatal(err) + } +}