From 68b9a063c5f73c4fd5efa5867ba767d4fdf4b0cf Mon Sep 17 00:00:00 2001 From: clowwindy Date: Sat, 12 Jul 2014 21:59:00 +0800 Subject: [PATCH] move tests and remove config.json --- .travis.yml | 14 +++++++------- config.json | 10 ---------- test.py => tests/test.py | 2 ++ test_latency.py => tests/test_latency.py | 0 4 files changed, 9 insertions(+), 17 deletions(-) delete mode 100644 config.json rename test.py => tests/test.py (98%) rename test_latency.py => tests/test_latency.py (100%) diff --git a/.travis.yml b/.travis.yml index 24e1d8f..85d7939 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,10 +12,10 @@ before_install: - pip install m2crypto salsa20 - sudo tests/socksify/install.sh script: - - python test.py -c tests/table.json - - python test.py -c tests/aes.json - - python test.py -c tests/salsa20.json - - python test.py -c tests/server-multi-ports.json - - python test.py -c tests/server-multi-passwd.json - - python test.py -c tests/server-multi-passwd-table.json - - python test.py -c tests/workers.json + - python tests/test.py -c tests/table.json + - python tests/test.py -c tests/aes.json + - python tests/test.py -c tests/salsa20.json + - python tests/test.py -c tests/server-multi-ports.json + - python tests/test.py -c tests/server-multi-passwd.json + - python tests/test.py -c tests/server-multi-passwd-table.json + - python tests/test.py -c tests/workers.json diff --git a/config.json b/config.json deleted file mode 100644 index 026ed38..0000000 --- a/config.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "server":"0.0.0.0", - "server_port":8388, - "local_port":1080, - "password":"barfoo!", - "timeout":300, - "method":"aes-256-cfb", - "local_address":"127.0.0.1", - "fast_open":false -} diff --git a/test.py b/tests/test.py similarity index 98% rename from test.py rename to tests/test.py index 594cfdc..da28e0b 100755 --- a/test.py +++ b/tests/test.py @@ -8,6 +8,8 @@ import select import time from subprocess import Popen, PIPE +sys.path.insert(0, '../') + if 'salsa20' in sys.argv[-1]: from shadowsocks import encrypt_salsa20 encrypt_salsa20.test() diff --git a/test_latency.py b/tests/test_latency.py similarity index 100% rename from test_latency.py rename to tests/test_latency.py