Skip to content

Commit

Permalink
Merge pull request #85 from richardartoul/ra/fix-broken-cancelation
Browse files Browse the repository at this point in the history
Fix broken context cancelation
  • Loading branch information
richardartoul authored May 29, 2023
2 parents d2520bc + 2a1ba59 commit 77abf02
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions virtual/environment_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1095,6 +1095,8 @@ func (ta *testActor) Invoke(
operation string,
payload []byte,
) ([]byte, error) {
// Check the context immediately to ensure we catch bugs related to
// canceling contexts prematurely.
if err := ctx.Err(); err != nil {
return nil, ctx.Err()
}
Expand Down

0 comments on commit 77abf02

Please sign in to comment.