From f206c24dfcf9bbc70d8551aaf6794d50d67feaa0 Mon Sep 17 00:00:00 2001 From: Isaac Boukris Date: Sun, 2 Aug 2015 06:02:19 +0300 Subject: More basic-auth tests Add test for second user on the same connection with the password of the first user and without auth at all. Reviewed-by: Simo Sorce Closes #48 --- tests/magtests.py | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'tests/magtests.py') diff --git a/tests/magtests.py b/tests/magtests.py index 1861f21..3e2f4fc 100755 --- a/tests/magtests.py +++ b/tests/magtests.py @@ -300,6 +300,16 @@ def test_basic_auth_krb5(testdir, testenv, testlog): else: sys.stderr.write('BASIC-AUTH Two Users: SUCCESS\n') + with (open(testlog, 'a')) as logfile: + basick5 = subprocess.Popen(["tests/t_basic_k5_fail_second.py"], + stdout=logfile, stderr=logfile, + env=testenv, preexec_fn=os.setsid) + basick5.wait() + if basick5.returncode != 0: + sys.stderr.write('BASIC Fail Second User: FAILED\n') + else: + sys.stderr.write('BASIC Fail Second User: SUCCESS\n') + with (open(testlog, 'a')) as logfile: basick5 = subprocess.Popen(["tests/t_basic_proxy.py"], stdout=logfile, stderr=logfile, -- cgit