X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=E2Manager%2Fmocks%2FrnibReaderMock.go;h=43f9d90536121f7974ec602fb66d05b5d7a62a15;hb=refs%2Fchanges%2F32%2F732%2F1;hp=fc98987cb62cdb4401a3a5568b1b3c3a93e82b58;hpb=57c3faebe7df51f7da6dcdcc6ae03927f380d1e4;p=ric-plt%2Fe2mgr.git diff --git a/E2Manager/mocks/rnibReaderMock.go b/E2Manager/mocks/rnibReaderMock.go index fc98987..43f9d90 100644 --- a/E2Manager/mocks/rnibReaderMock.go +++ b/E2Manager/mocks/rnibReaderMock.go @@ -17,8 +17,8 @@ package mocks import ( - "gerrit.o-ran-sc.org/r/ric-plt/nodeb-rnib.git/entities" "gerrit.o-ran-sc.org/r/ric-plt/nodeb-rnib.git/common" + "gerrit.o-ran-sc.org/r/ric-plt/nodeb-rnib.git/entities" "github.com/stretchr/testify/mock" ) @@ -29,10 +29,9 @@ type RnibReaderMock struct { func (m *RnibReaderMock) GetNodeb(inventoryName string) (*entities.NodebInfo, common.IRNibError) { args := m.Called(inventoryName) - errArg := args.Get(1); - if (errArg != nil) { + if errArg != nil { return args.Get(0).(*entities.NodebInfo), errArg.(common.IRNibError); } @@ -44,43 +43,43 @@ func (m *RnibReaderMock) GetNodebByGlobalNbId(nodeType entities.Node_Type, globa errArg := args.Get(1); - if (errArg != nil) { + if errArg != nil { return args.Get(0).(*entities.NodebInfo), errArg.(common.IRNibError); } return args.Get(0).(*entities.NodebInfo), nil } -func (m *RnibReaderMock) GetCellList(inventoryName string) (*entities.Cells, common.IRNibError) { +func (m *RnibReaderMock) GetCellList(inventoryName string) (*entities.Cells, common.IRNibError) { args := m.Called(inventoryName) errArg := args.Get(1); - if (errArg != nil) { + if errArg != nil { return args.Get(0).(*entities.Cells), errArg.(common.IRNibError); } return args.Get(0).(*entities.Cells), nil } -func (m *RnibReaderMock) GetListGnbIds()(*[]*entities.NbIdentity, common.IRNibError) { +func (m *RnibReaderMock) GetListGnbIds() (*[]*entities.NbIdentity, common.IRNibError) { args := m.Called() errArg := args.Get(1); - if (errArg != nil) { + if errArg != nil { return args.Get(0).(*[]*entities.NbIdentity), errArg.(common.IRNibError); } return args.Get(0).(*[]*entities.NbIdentity), nil } -func (m *RnibReaderMock) GetListEnbIds()(*[]*entities.NbIdentity, common.IRNibError) { +func (m *RnibReaderMock) GetListEnbIds() (*[]*entities.NbIdentity, common.IRNibError) { args := m.Called() errArg := args.Get(1); - if (errArg != nil) { + if errArg != nil { return args.Get(0).(*[]*entities.NbIdentity), errArg.(common.IRNibError); } @@ -88,12 +87,12 @@ func (m *RnibReaderMock) GetListEnbIds()(*[]*entities.NbIdentity, common.IRNibEr } -func (m *RnibReaderMock) GetCountGnbList()(int, common.IRNibError) { +func (m *RnibReaderMock) GetCountGnbList() (int, common.IRNibError) { args := m.Called() errArg := args.Get(1); - if (errArg != nil) { + if errArg != nil { return args.Int(0), errArg.(common.IRNibError); } @@ -106,7 +105,7 @@ func (m *RnibReaderMock) GetCell(inventoryName string, pci uint32) (*entities.Ce errArg := args.Get(1); - if (errArg != nil) { + if errArg != nil { return args.Get(0).(*entities.Cell), errArg.(common.IRNibError); } @@ -118,14 +117,14 @@ func (m *RnibReaderMock) GetCellById(cellType entities.Cell_Type, cellId string) errArg := args.Get(1); - if (errArg != nil) { + if errArg != nil { return args.Get(0).(*entities.Cell), errArg.(common.IRNibError); } return args.Get(0).(*entities.Cell), nil } -func (m *RnibReaderMock) GetListNodebIds()([]*entities.NbIdentity, common.IRNibError){ +func (m *RnibReaderMock) GetListNodebIds() ([]*entities.NbIdentity, common.IRNibError) { args := m.Called() errArg := args.Get(1) @@ -137,7 +136,7 @@ func (m *RnibReaderMock) GetListNodebIds()([]*entities.NbIdentity, common.IRNibE return args.Get(0).([]*entities.NbIdentity), nil } -func (m *RnibReaderMock) GetRanLoadInformation(inventoryName string) (*entities.RanLoadInformation, common.IRNibError){ +func (m *RnibReaderMock) GetRanLoadInformation(inventoryName string) (*entities.RanLoadInformation, common.IRNibError) { args := m.Called() errArg := args.Get(1) @@ -147,4 +146,4 @@ func (m *RnibReaderMock) GetRanLoadInformation(inventoryName string) (*entities. } return args.Get(0).(*entities.RanLoadInformation), nil -} \ No newline at end of file +}