Sha256: a4388eb09511ca86abbb0769f4185e064a529488da03db67762c852d3a8091b1
Contents?: true
Size: 583 Bytes
Versions: 13
Compression:
Stored size: 583 Bytes
Contents
require ::File.expand_path('../resource.pb', __FILE__) Test::ResourceService.class_eval do # request -> Test::ResourceFindRequest # response -> Test::Resource def find response.name = request.name response.status = request.active ? 1 : 0 end # request -> Test::ResourceSleepRequest # response -> Test::Resource def find_with_sleep sleep(request.sleep || 1) response.name = 'Request should have timed out' end # request -> Test::ResourceFindRequest # response -> Test::Resource def find_with_rpc_failed rpc_failed('Find failed') end end
Version data entries
13 entries across 13 versions & 2 rubygems