repo.or.cz
/
kgio.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
history
|
raw
|
HEAD
accept: prepare optional flags argument to accept() wrappers
[kgio.git]
/
test
/
test_unix_server.rb
blob
faa82090ea2cbff288bb5abd45246e6b69d26889
1
require 'tempfile'
2
require './test/lib_server_accept'
3
4
class TestKgioUNIXServer < Test::Unit::TestCase
5
6
def setup
7
tmp = Tempfile.new('kgio_unix')
8
@path = tmp.path
9
File.unlink(@path)
10
tmp.close rescue nil
11
@srv = Kgio::UNIXServer.new(@path)
12
@host = '127.0.0.1'
13
end
14
15
def client_connect
16
UNIXSocket.new(@path)
17
end
18
19
include LibServerAccept
20
end