Skip to content

Commit

Permalink
Update UT
Browse files Browse the repository at this point in the history
Signed-off-by: bingwang <wang.bing@microsoft.com>
  • Loading branch information
bingwang-ms committed Mar 30, 2022
1 parent e8ab4be commit 1f0609b
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
7 changes: 7 additions & 0 deletions unittest/lib/test_sai_redis_tunnel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,11 @@ TEST(libsairedis, tunnel)
EXPECT_NE(SAI_STATUS_SUCCESS, api->remove_tunnel_map_entry(0));
EXPECT_NE(SAI_STATUS_SUCCESS, api->set_tunnel_map_entry_attribute(0,0));
EXPECT_NE(SAI_STATUS_SUCCESS, api->get_tunnel_map_entry_attribute(0,0,0));

uint32_t attr_count = 0;
sai_status_t status = 0;
sai_attribute_t *p_attr = nullptr;
EXPECT_NE(SAI_STATUS_SUCCESS, api->get_tunnels_attribute(0,&id,&attr_count,&p_attr,SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR,&status));
EXPECT_NE(SAI_STATUS_SUCCESS, api->set_tunnels_attribute(0,&id,0,SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR,&status));
}

7 changes: 7 additions & 0 deletions unittest/vslib/test_sai_vs_tunnel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,11 @@ TEST(libsaivs, tunnel)
EXPECT_NE(SAI_STATUS_SUCCESS, api->remove_tunnel_map_entry(0));
EXPECT_NE(SAI_STATUS_SUCCESS, api->set_tunnel_map_entry_attribute(0,0));
EXPECT_NE(SAI_STATUS_SUCCESS, api->get_tunnel_map_entry_attribute(0,0,0));

uint32_t attr_count = 0;
sai_status_t status = 0;
sai_attribute_t *p_attr = nullptr;
EXPECT_NE(SAI_STATUS_SUCCESS, api->get_tunnels_attribute(0,&id,&attr_count,&p_attr,SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR,&status));
EXPECT_NE(SAI_STATUS_SUCCESS, api->set_tunnels_attribute(0,&id,0,SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR,&status));
}

0 comments on commit 1f0609b

Please sign in to comment.