diff options
author | Matěj Cepl <mcepl@cepl.eu> | 2014-12-31 12:12:02 +0100 |
---|---|---|
committer | Matěj Cepl <mcepl@cepl.eu> | 2014-12-31 12:12:02 +0100 |
commit | 527e535279dcceeb6ffcf091bc9e8fc23b46f287 (patch) | |
tree | 5a2c6bbeed90ee47e4a13dcfa854df6513a775f2 /test | |
parent | cdd9f1d6a872fbc20e368fc23ddaf98eb1ef3741 (diff) | |
download | pygn-527e535279dcceeb6ffcf091bc9e8fc23b46f287.tar.gz |
Remove the spaghetti code from the main scripts.
Diffstat (limited to 'test')
-rwxr-xr-x | test/test_wlp.py | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/test/test_wlp.py b/test/test_wlp.py index 759dffe..4dd1516 100755 --- a/test/test_wlp.py +++ b/test/test_wlp.py @@ -1,14 +1,15 @@ #!/usr/bin/python # -*- coding: utf-8 -*- -import unittest -import sysconfig -import sys +import mail2news import os import os.path -import subprocess import re -import mail2news +import subprocess +import sys +import sysconfig +import unittest +import wlp def distutils_dir_name(dname): @@ -21,7 +22,6 @@ wlp_lib_path = os.path.join('build', distutils_dir_name('lib')) sys.path.insert(0, wlp_lib_path) -import wlp class TestWLP(unittest.TestCase): @@ -61,7 +61,7 @@ one line test def test_m2n(self): with open('examples/mail') as in_mail: - pid = subprocess.Popen(['./pygm2n', '-TV', '-n', 'pyg.test'], + pid = subprocess.Popen(['./pygm2n', '-Tv', '-n', 'pyg.test'], stdin=subprocess.PIPE, stdout=subprocess.PIPE) out, _ = pid.communicate(in_mail.read()) @@ -93,8 +93,8 @@ Resent-Sender: sender@example.com env['PYTHONPATH'] = wlp_lib_path with open('examples/articletest.accepted') as in_mail: - pid = subprocess.Popen(['./pygn2m', '-TVt', 'test@example.com', - '-s', 'sender@example.com', '-d', + pid = subprocess.Popen(['./pygn2m', '-Tvt', 'test@example.com', + '-s', 'sender@example.com', '-w', 'examples/whitelist.example'], stdin=subprocess.PIPE, stdout=subprocess.PIPE, env=env) |