mirror of
https://github.com/priyanshujain/sanderling.git
synced 2026-10-03 11:37:09 +00:00
refactor(runner): drop the empty branch from the hold path
This commit is contained in:
1 parent
5aee168098
commit
7d4e85f407
1 file changed
+5
-5
@@ -318,10 +318,7 @@ func Run(ctx context.Context, options Options) (Summary, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
applySkipped := held
|
applySkipped := held
|
||||||
if held {
|
if nextErr == nil && !appIsForeground(ctx, options) {
|
||||||
// lastAction is left exactly as it is: it is still the action the
|
|
||||||
// next verified step has to be told about.
|
|
||||||
} else if nextErr == nil && !appIsForeground(ctx, options) {
|
|
||||||
// The app left the foreground between observe and apply (a prior
|
// The app left the foreground between observe and apply (a prior
|
||||||
// action's gesture settling late, or an async navigation). The
|
// action's gesture settling late, or an async navigation). The
|
||||||
// chosen action's coordinates reference a tree that no longer
|
// chosen action's coordinates reference a tree that no longer
|
||||||
@@ -365,9 +362,12 @@ func Run(ctx context.Context, options Options) (Summary, error) {
|
|||||||
applied.Applied = true
|
applied.Applied = true
|
||||||
lastAction = &applied
|
lastAction = &applied
|
||||||
}
|
}
|
||||||
} else {
|
} else if !held {
|
||||||
lastAction = nil
|
lastAction = nil
|
||||||
}
|
}
|
||||||
|
// A held step leaves lastAction alone on purpose: nothing ran here, and
|
||||||
|
// the action it points at is still the one the next verified step has to
|
||||||
|
// be told about.
|
||||||
|
|
||||||
step := trace.Step{
|
step := trace.Step{
|
||||||
Index: stepIndex,
|
Index: stepIndex,
|
||||||
|
|||||||
Reference in new issue
Block a user