Tests: added access log test with unix socket.

This commit is contained in:
Andrey Zelenkov
2018-04-23 15:26:52 +03:00
parent b6226d6945
commit 0658f9bd71

View File

@@ -97,6 +97,26 @@ Connection: close
self.search_in_log(
r'::1 - - \[.+\] "GET / HTTP/1.1" 200 0 "-" "-"'), 'ipv6')
def test_access_log_unix(self):
self.load('empty')
addr = self.testdir + '/sock'
self.conf({
"unix:" + addr: {
"application": "empty"
}
}, '/listeners')
self.get(sock_type='unix', addr=addr)
time.sleep(0.2)
self.stop()
self.assertIsNotNone(self.search_in_log(
r'unix: - - \[.+\] "GET / HTTP/1.1" 200 0 "-" "-"'), 'unix')
def test_access_log_referer(self):
self.load('empty')