From dab97b33141d0655a311e1c63bb3f21f28df2aa8 Mon Sep 17 00:00:00 2001 From: Paul BESRET Date: Fri, 8 Nov 2024 12:09:38 +0100 Subject: [PATCH] Fixed go client tests --- internal/client/compute_content_library_test.go | 4 +++- internal/client/compute_network_test.go | 2 +- internal/client/compute_virtual_switch_test.go | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/internal/client/compute_content_library_test.go b/internal/client/compute_content_library_test.go index 86b5bc4..1248c3f 100644 --- a/internal/client/compute_content_library_test.go +++ b/internal/client/compute_content_library_test.go @@ -59,7 +59,9 @@ func TestCompute_ContentLibraryRead(t *testing.T) { func TestContentLibraryClient_ListItems(t *testing.T) { ctx := context.Background() - items, err := client.Compute().ContentLibrary().ListItems(ctx, os.Getenv(ContentLibraryId)) + items, err := client.Compute().ContentLibrary().ListItems(ctx, &ContentLibraryItemFilter{ + ContentLibraryId: os.Getenv(ContentLibraryId), + }) require.NoError(t, err) require.GreaterOrEqual(t, len(items), 1) diff --git a/internal/client/compute_network_test.go b/internal/client/compute_network_test.go index 011775f..1607d47 100644 --- a/internal/client/compute_network_test.go +++ b/internal/client/compute_network_test.go @@ -16,7 +16,7 @@ const ( func TestCompute_NetworkList(t *testing.T) { ctx := context.Background() - networks, err := client.Compute().Network().List(ctx, "", "", "", "", "", "", "", "", true) + networks, err := client.Compute().Network().List(ctx, &NetworkFilter{}) require.NoError(t, err) require.GreaterOrEqual(t, len(networks), 1) diff --git a/internal/client/compute_virtual_switch_test.go b/internal/client/compute_virtual_switch_test.go index 054a93e..6323cb3 100644 --- a/internal/client/compute_virtual_switch_test.go +++ b/internal/client/compute_virtual_switch_test.go @@ -16,7 +16,7 @@ const ( func TestCompute_VirtualSwitchList(t *testing.T) { ctx := context.Background() - virtualSwitchs, err := client.Compute().VirtualSwitch().List(ctx, "", "", "") + virtualSwitchs, err := client.Compute().VirtualSwitch().List(ctx, &VirtualSwitchFilter{}) require.NoError(t, err) require.GreaterOrEqual(t, len(virtualSwitchs), 1)