mirror of
https://github.com/Grasscutters/mitmproxy.git
synced 2024-11-23 08:11:00 +00:00
Zap a left-over test
This commit is contained in:
parent
f2bc58cdd2
commit
dabb356c15
@ -1,6 +1,5 @@
|
||||
from cStringIO import StringIO
|
||||
import socket
|
||||
import mock
|
||||
from nose.plugins.skip import SkipTest
|
||||
from netlib import socks, tcp
|
||||
import tutils
|
||||
@ -83,14 +82,3 @@ def test_message_unknown_atyp():
|
||||
|
||||
m = socks.Message(5, 1, 0x02, tcp.Address(("example.com", 5050)))
|
||||
tutils.raises(socks.SocksError, m.to_file, StringIO())
|
||||
|
||||
def test_read():
|
||||
cs = StringIO("1234")
|
||||
assert socks._read(cs, 3) == "123"
|
||||
|
||||
cs = StringIO("123")
|
||||
tutils.raises(socks.SocksError, socks._read, cs, 4)
|
||||
|
||||
cs = mock.Mock()
|
||||
cs.read = mock.Mock(side_effect=socket.error)
|
||||
tutils.raises(socks.SocksError, socks._read, cs, 4)
|
||||
|
Loading…
Reference in New Issue
Block a user