func TestDeleteLogicalInterconnectGroup(t *testing.T) { var ( d *OVTest c *ov.OVClient testName string testLogicalInterconnectGroup ov.LogicalInterconnectGroup ) if os.Getenv("ONEVIEW_TEST_ACCEPTANCE") == "true" { d, c = getTestDriverA("test_logical_interconnect_group") if c == nil { t.Fatalf("Failed to execute getTestDriver() ") } testName = d.Tc.GetTestData(d.Env, "Name").(string) err := c.DeleteLogicalInterconnectGroup(testName) assert.NoError(t, err, "DeleteLogicalInterconnectGroup err-> %s", err) testLogicalInterconnectGroup, err = c.GetLogicalInterconnectGroupByName(testName) assert.NoError(t, err, "GetLogicalInterconnectGroupByName with deleted logical interconnect gorup-> %+v", err) assert.Equal(t, "", testLogicalInterconnectGroup.Name, fmt.Sprintf("Problem getting logicalInterconnectGroup name, %+v", testLogicalInterconnectGroup)) } else { _, c = getTestDriverU("test_logical_interconnect_group") err := c.DeleteLogicalInterconnectGroup("footest") assert.Error(t, err, fmt.Sprintf("ALL ok, no error, caught as expected: %s,%+v\n", err, testLogicalInterconnectGroup)) } }