projects
/
gssweb.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
Add a ruby script for interactive command line testing of json_gssapi
[gssweb.git]
/
json_gssapi
/
test.rb
1
#!/usr/bin/ruby
2
3
require 'open3'
4
5
Open3.popen2('./json_gssapi') do |inIo, outIo, wait_thr|
6
puts "gdb --pid=#{wait_thr.pid}"
7
while(true) do
8
a = gets
9
inIo.puts [a.length].pack('L') + a
10
inIo.flush
11
12
outIo.flush
13
b = outIo.read(4)
14
puts b
15
c = outIo.read(b.unpack('L')[0])
16
puts c
17
end
18
end
19