mirror of
https://github.com/k8snetworkplumbingwg/multus-cni.git
synced 2025-10-21 23:48:25 +00:00
adding k8sclient bug fixes
This commit is contained in:
committed by
Kuralamudhan Ramakrishnan
parent
7372922617
commit
707007abba
@@ -77,7 +77,7 @@ func LoadDelegateNetConf(bytes []byte, ifnameRequest string) (*DelegateNetConf,
|
||||
// Do some minimal validation
|
||||
if delegateConf.Conf.Type == "" {
|
||||
if err := LoadDelegateNetConfList(bytes, delegateConf); err != nil {
|
||||
return nil, fmt.Errorf("error in LoadDelegateNetConf: %v")
|
||||
return nil, fmt.Errorf("error in LoadDelegateNetConf: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -40,7 +40,7 @@ var _ = Describe("config operations", func() {
|
||||
netConf, err := LoadNetConf([]byte(conf))
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
Expect(len(netConf.Delegates)).To(Equal(1))
|
||||
Expect(netConf.Delegates[0].Type).To(Equal("weave-net"))
|
||||
Expect(netConf.Delegates[0].Conf.Type).To(Equal("weave-net"))
|
||||
Expect(netConf.Delegates[0].MasterPlugin).To(BeTrue())
|
||||
})
|
||||
|
||||
@@ -57,9 +57,9 @@ var _ = Describe("config operations", func() {
|
||||
netConf, err := LoadNetConf([]byte(conf))
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
Expect(len(netConf.Delegates)).To(Equal(2))
|
||||
Expect(netConf.Delegates[0].Type).To(Equal("weave-net"))
|
||||
Expect(netConf.Delegates[0].Conf.Type).To(Equal("weave-net"))
|
||||
Expect(netConf.Delegates[0].MasterPlugin).To(BeTrue())
|
||||
Expect(netConf.Delegates[1].Type).To(Equal("foobar"))
|
||||
Expect(netConf.Delegates[1].Conf.Type).To(Equal("foobar"))
|
||||
Expect(netConf.Delegates[1].MasterPlugin).To(BeFalse())
|
||||
})
|
||||
|
||||
|
Reference in New Issue
Block a user