adding unit test fixes

This commit is contained in:
Kuralamudhan Ramakrishnan
2019-03-26 14:28:30 +00:00
parent 4af9369fef
commit d4bea58766

View File

@@ -514,7 +514,7 @@ var _ = Describe("multus operations", func() {
Expect(fExec.addIndex).To(Equal(len(fExec.plugins)))
Expect(fKubeClient.PodCount).To(Equal(2))
Expect(fKubeClient.NetCount).To(Equal(1))
r := result.(*types020.Result)
r, _ := result.GetAsVersion("0.2.0")
// plugin 1 is the masterplugin
Expect(reflect.DeepEqual(r, expectedResult1)).To(BeTrue())
@@ -614,7 +614,7 @@ var _ = Describe("multus operations", func() {
Expect(fExec.addIndex).To(Equal(len(fExec.plugins)))
Expect(fKubeClient.PodCount).To(Equal(2))
Expect(fKubeClient.NetCount).To(Equal(2))
r := result.(*types020.Result)
r, _ := result.GetAsVersion("0.2.0")
Expect(reflect.DeepEqual(r, expectedResult1)).To(BeTrue())
os.Setenv("CNI_COMMAND", "DEL")
@@ -683,7 +683,7 @@ var _ = Describe("multus operations", func() {
Expect(fExec.addIndex).To(Equal(len(fExec.plugins)))
Expect(fKubeClient.PodCount).To(Equal(2))
Expect(fKubeClient.NetCount).To(Equal(1))
r := result.(*types020.Result)
r, _ := result.GetAsVersion("0.2.0")
// plugin 1 is the masterplugin
Expect(reflect.DeepEqual(r, expectedResult1)).To(BeTrue())
@@ -761,7 +761,7 @@ var _ = Describe("multus operations", func() {
Expect(fExec.addIndex).To(Equal(len(fExec.plugins)))
Expect(fKubeClient.PodCount).To(Equal(2))
Expect(fKubeClient.NetCount).To(Equal(1))
r := result.(*types020.Result)
r, _ := result.GetAsVersion("0.2.0")
// plugin 1 is the masterplugin
Expect(reflect.DeepEqual(r, expectedResult1)).To(BeTrue())