summaryrefslogtreecommitdiffhomepage
path: root/test/test_tls.py
diff options
context:
space:
mode:
authorAndrei Belov <defan@nginx.com>2020-02-06 18:25:25 +0300
committerAndrei Belov <defan@nginx.com>2020-02-06 18:25:25 +0300
commit2dc01938cf02cc05b41a09e618f712129c4cdf91 (patch)
tree556dd40a0ec8c194774d53eed9ff62ed1d25ee7c /test/test_tls.py
parent477a58e14010ab14d6ab453860b360cf806f5012 (diff)
parent6e19090736612b39d4c5d0836d7df0722b8955e7 (diff)
downloadunit-2dc01938cf02cc05b41a09e618f712129c4cdf91.tar.gz
unit-2dc01938cf02cc05b41a09e618f712129c4cdf91.tar.bz2
Merged with the default branch.1.15.0-1
Diffstat (limited to 'test/test_tls.py')
-rw-r--r--test/test_tls.py22
1 files changed, 22 insertions, 0 deletions
diff --git a/test/test_tls.py b/test/test_tls.py
index 3514bbcb..1ead111c 100644
--- a/test/test_tls.py
+++ b/test/test_tls.py
@@ -1,3 +1,5 @@
+import io
+import os
import re
import ssl
import subprocess
@@ -591,5 +593,25 @@ basicConstraints = critical,CA:TRUE"""
'url scheme https',
)
+ def test_tls_big_upload(self):
+ self.load('upload')
+
+ self.certificate()
+
+ self.add_tls(application='upload')
+
+ filename = 'test.txt'
+ data = '0123456789' * 9000
+
+ res = self.post_ssl(body={
+ 'file': {
+ 'filename': filename,
+ 'type': 'text/plain',
+ 'data': io.StringIO(data),
+ }
+ })
+ self.assertEqual(res['status'], 200, 'status ok')
+ self.assertEqual(res['body'], filename + data)
+
if __name__ == '__main__':
TestTLS.main()