aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/ruby/bin
diff options
context:
space:
mode:
authorGravatar Tim Emiola <temiola@google.com>2015-06-17 11:52:51 -0700
committerGravatar Tim Emiola <temiola@google.com>2015-06-19 10:23:42 -0700
commitaa57bab3ca99f621f042b0a3985b36a0e0e2d6f6 (patch)
tree63cb8a1f03780781e3add6e3b7abff948d4246c5 /src/ruby/bin
parenta15f08cc9a8004785ec937b2ee06951b600d87b6 (diff)
Corrects the cancel_after_first_response behaviour
- introduces a #wait method on the call operation view - invokes #wait on a Notifier that is created for all operations - ensures the Notifier is invoked if necessary whenever a client request completes - updates the interop_test to use op.wait before checking if the call was cancelled.
Diffstat (limited to 'src/ruby/bin')
-rwxr-xr-xsrc/ruby/bin/interop/interop_client.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ruby/bin/interop/interop_client.rb b/src/ruby/bin/interop/interop_client.rb
index 16fb1b199d..da4caa842b 100755
--- a/src/ruby/bin/interop/interop_client.rb
+++ b/src/ruby/bin/interop/interop_client.rb
@@ -284,7 +284,8 @@ class NamedTests
op = @stub.full_duplex_call(ppp.each_item, return_op: true)
ppp.canceller_op = op # causes ppp to cancel after the 1st message
op.execute.each { |r| ppp.queue.push(r) }
- assert(op.cancelled, 'call operation should be CANCELLED')
+ op.wait
+ assert(op.cancelled, 'call operation was not CANCELLED')
p 'OK: cancel_after_first_response'
end