Skip to content

Commit

Permalink
Fix unit test for CreateARecord()
Browse files Browse the repository at this point in the history
Plus, a couple of minor gofmt fixes.
  • Loading branch information
rhossili committed Aug 15, 2021
1 parent 87a6109 commit 1a197d6
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions object_manager_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ var _ = Describe("Object Manager", func() {
comment := "test comment 1"
updateNetviewName := "default_view"
updatedRef := fmt.Sprintf("networkview/%s:%s", refBase, updateNetviewName)
updateObjIn := NewNetworkView(updateNetviewName, comment, expectedEas, ref)
updateObjIn := NewNetworkView(updateNetviewName, comment, expectedEas, ref)

expectedObj := NewNetworkView(updateNetviewName, comment, expectedEas, updatedRef)

Expand Down Expand Up @@ -1871,7 +1871,7 @@ var _ = Describe("Object Manager", func() {
getObjectRef: "",
getObjectObj: NewEmptyRecordA(),
getObjectQueryParams: queryParams,
resultObject: []RecordA{*NewRecordA(dnsView, "", recordName, ipAddr, 0,false, "", nil, fakeRefReturn)},
resultObject: []RecordA{*NewRecordA(dnsView, "", recordName, ipAddr, 0, false, "", nil, fakeRefReturn)},
fakeRefReturn: fakeRefReturn,
}

Expand Down Expand Up @@ -1924,7 +1924,6 @@ var _ = Describe("Object Manager", func() {
})

Describe("Create an A-record by allocating next available IP address", func() {
return
cmpType := "Docker"
tenantID := "01234567890abcdef01234567890abcdef"
netviewName := "private"
Expand All @@ -1945,6 +1944,9 @@ var _ = Describe("Object Manager", func() {
aniFakeConnector := &fakeConnector{
createObjectObj: NewRecordA(
dnsView, "", recordName, ipAddrFunc, 0, false, "", nil, ""),
getObjectRef: fakeRefReturn,
getObjectObj: NewEmptyRecordA(),
getObjectQueryParams: NewQueryParams(false, nil),
resultObject: NewRecordA(
dnsView, "", recordName, ipAddrRes, 0, false, "", nil, fakeRefReturn),
fakeRefReturn: fakeRefReturn,
Expand Down

0 comments on commit 1a197d6

Please sign in to comment.