Fixed stc to properly account for skipped steps when completing enclosing group.
Change-Id: I9b297f8a48a9f4423e34fbbb954bf039e98e29b8
diff --git a/utils/stc/src/main/java/org/onlab/stc/Coordinator.java b/utils/stc/src/main/java/org/onlab/stc/Coordinator.java
index 123ef7d..a26e9fe 100644
--- a/utils/stc/src/main/java/org/onlab/stc/Coordinator.java
+++ b/utils/stc/src/main/java/org/onlab/stc/Coordinator.java
@@ -217,8 +217,8 @@
if (step instanceof Group) {
Group group = (Group) step;
group.children().forEach(child -> delegate.onCompletion(child, SKIPPED));
- delegate.onCompletion(step, SKIPPED);
}
+ delegate.onCompletion(step, SKIPPED);
}
}
@@ -268,7 +268,7 @@
boolean failed = false;
for (Step child : group.children()) {
Status status = store.getStatus(child);
- done = done && (status == SUCCEEDED || status == FAILED);
+ done = done && (status == SUCCEEDED || status == FAILED || status == SKIPPED);
failed = failed || status == FAILED;
}
if (done) {