Add extra delay after state engine integration tests

This ensures target state has settled (since it seems that the 'applied' status
that's reported isn't 100% accurate and the actual Engine state may lag behind slightly)

Signed-off-by: Christina Ying Wang <christina@balena.io>
This commit is contained in:
Christina Ying Wang 2023-05-30 15:17:11 -07:00
parent 7f32141958
commit 95f3e13d50

View File

@ -49,6 +49,8 @@ const setTargetState = async (
while (true) {
const status = await getStatus();
if (status.appState === 'applied') {
// Wait a tiny bit more after applied for state to settle
await delay(1000);
clearTimeout(timer);
resolve(true);
break;