Commit 364ab0d8 authored by Pawel Boening's avatar Pawel Boening

style fixes

parent b861e178
Pipeline #6583 passed with stage
in 5 minutes and 45 seconds
# pylint: disable=too-many-public-methods
import os
import socket
import ssl
......@@ -193,7 +195,7 @@ class TestConnection(unittest.TestCase):
self.assertResponse(250, '.\r\n')
self.assertResponse(221, 'quIT\r\n')
def test_ehlo(self):
def test_ehlo_fail(self):
self.assertResponse(250, 'EHLO marschke.me\r\n')
self.assertResponse(500, 'FAIL\r\n')
......@@ -282,16 +284,9 @@ class TestConnection(unittest.TestCase):
self.assertResponse(500, b'VRFZ\r\n')
self.assertResponse(250, b'NOOP\r\n')
def test_post_invalid_parameter_stability_0(self):
self.assertResponse(250, b'EHLO localhost\r\n')
self.assertResponse(500, b'MAIL wrong input blabla\r\n')
self.assertResponse(250, b'MAIL FROM:<correct.mail@test.de>\r\n')
def test_quit_operation(self):
pass
# TODO:
def test_post_invalid_parameter_stability_0(self):
self.assertResponse(250, b'EHLO localhost\r\n')
self.assertResponse(500, b'MAIL wrong input blabla\r\n')
......@@ -318,7 +313,7 @@ class TestConnection(unittest.TestCase):
def test_ehlo(self):
self.assertResponse(250, b'EHLO localDomain\r\n')
def test_ehlo(self):
def test_ehlo_dot(self):
self.assertResponse(250, b'EHLO localDomain.de\r\n')
def test_ehlo_no_domain(self):
......@@ -342,10 +337,10 @@ class TestConnection(unittest.TestCase):
self.client.send(b'SOME_RANDOM_TEXT\r\n')
self.assertResponse(250, b'.\r\n')
mail_location = subprocess.check_output(['sudo',
'docker',
'exec',
'{}'.format(self.test_server.docker_id.decode('utf-8')),
'grep',
'-r',
'SOME_RANDOM_TEXT'])
subprocess.check_output(['sudo',
'docker',
'exec',
'{}'.format(self.test_server.docker_id.decode('utf-8')),
'grep',
'-r',
'SOME_RANDOM_TEXT'])
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment