Configure full Docker setup and confirm consequential actions
This commit is contained in:
@@ -166,7 +166,14 @@ func TestRetryReplaysInitialInputAndPinnedVersionThroughCLI(t *testing.T) {
|
||||
}
|
||||
return result, err
|
||||
}
|
||||
result, err := runCLI("retry", fmt.Sprint(original.ID), "--json", "--wait", "--timeout", "5s", "--request-key", "retry-key")
|
||||
if _, err := runCLI("retry", fmt.Sprint(original.ID), "--json"); err == nil || !strings.Contains(err.Error(), "action canceled") {
|
||||
t.Fatal("unconfirmed retry accepted", err)
|
||||
}
|
||||
beforeRetry, err := store.ListRuns(ctx)
|
||||
if err != nil || len(beforeRetry) != 1 {
|
||||
t.Fatal("unconfirmed retry created a run", err)
|
||||
}
|
||||
result, err := runCLI("retry", fmt.Sprint(original.ID), "--yes", "--json", "--wait", "--timeout", "5s", "--request-key", "retry-key")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
@@ -175,7 +182,7 @@ func TestRetryReplaysInitialInputAndPinnedVersionThroughCLI(t *testing.T) {
|
||||
t.Fatal("retry did not preserve recorded run settings", retried)
|
||||
}
|
||||
r.wg.Wait()
|
||||
again, err := runCLI("retry", fmt.Sprint(original.ID), "--json", "--request-key", "retry-key")
|
||||
again, err := runCLI("retry", fmt.Sprint(original.ID), "--yes", "--json", "--request-key", "retry-key")
|
||||
if err != nil || again.RunDetail.ID != retried.ID {
|
||||
t.Fatal("retry lost idempotency", again, err)
|
||||
}
|
||||
@@ -183,7 +190,7 @@ func TestRetryReplaysInitialInputAndPinnedVersionThroughCLI(t *testing.T) {
|
||||
if err != nil || !reflect.DeepEqual(original, unchanged) {
|
||||
t.Fatal("retry modified failed history", unchanged, err)
|
||||
}
|
||||
if _, err := runCLI("retry", fmt.Sprint(retried.ID), "--json"); err == nil {
|
||||
if _, err := runCLI("retry", fmt.Sprint(retried.ID), "--yes", "--json"); err == nil {
|
||||
t.Fatal("succeeded run accepted for retry")
|
||||
}
|
||||
if _, err := r.retry(protocol.Message{RunID: original.ID}); err == nil {
|
||||
|
||||
Reference in New Issue
Block a user