Skip to content

Commit 6159781

Browse files
log/test: [WIN-NPM] log when we finish bootup phase & make UT more consistent (#2001)
* log: indicate when we finish bootup phase * test: add extra apply DP for multi job UTs * test: check error for applydp
1 parent 40454b7 commit 6159781

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

npm/pkg/dataplane/dataplane.go

+1
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,7 @@ func (dp *DataPlane) FinishBootupPhase() {
134134
dp.applyInfo.Lock()
135135
defer dp.applyInfo.Unlock()
136136

137+
klog.Infof("[DataPlane] finished bootup phase")
137138
dp.applyInfo.inBootupPhase = false
138139
}
139140

npm/pkg/dataplane/dataplane_windows_test.go

+2
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,8 @@ func testMultiJobCases(t *testing.T, tests []*MultiJobTestCase, finalSleep time.
182182
require.FailNow(t, "encountered errors in multi-job test: %+v", errStrings)
183183
}
184184

185+
// just care about eventual consistency, so add extra applyDP e.g. in case finishBootupPhase() runs last
186+
require.NoError(t, dp.applyDataPlaneNow("UT FINAL APPLY"))
185187
dptestutils.VerifyHNSCache(t, hns, tt.ExpectedSetPolicies, tt.ExpectedEnpdointACLs)
186188
})
187189
}

0 commit comments

Comments
 (0)