summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfumingwei <[email protected]>2020-09-14 19:39:34 +0800
committerfumingwei <[email protected]>2020-09-14 19:39:34 +0800
commitcf837c0958ce45d0eff820dd5c28475d56544bf7 (patch)
tree07849985a2ea531033ef50abfed1fd297fc5f5a7
parentccdff3bbffe84a7502c6ab136f9b75ebca1abeb3 (diff)
1、增加读取配置文件2、增加开始运行时随机delay 时间test-v1.0.2-20200915
-rw-r--r--unittest_python/unittest/etc/tsg-diagnose.config159
-rw-r--r--unittest_python/unittest/tsg_diagnose.conf120
2 files changed, 159 insertions, 120 deletions
diff --git a/unittest_python/unittest/etc/tsg-diagnose.config b/unittest_python/unittest/etc/tsg-diagnose.config
new file mode 100644
index 0000000..22fb824
--- /dev/null
+++ b/unittest_python/unittest/etc/tsg-diagnose.config
@@ -0,0 +1,159 @@
+[test_securityPolicy_bypass]
+url = https://sha384.badssl.self-test.geedge.net
+# enabled = 1 run this case
+enabled = 1
+#Connection TIMEOUT, in seconds
+conn_timeout = 1
+#max_recv_speed_large byte/s
+max_recv_speed_large = 6553600
+
+[test_securityPolicy_intercept]
+url = https://sha256.badssl.self-test.geedge.net
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_securityPolicy_intercept_certerrExpired]
+url = https://expired.badssl.self-test.geedge.net
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_securityPolicy_intercept_certerrSelf_signed]
+url = https://self-signed.badssl.self-test.geedge.net
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_securityPolicy_intercept_certerrUntrusted_root]
+url = https://untrusted-root.badssl.self-test.geedge.net
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_proxyPolicy_ssl_redirect]
+url = https://cn.bing.com/rs/2V/pE/cj,nj/b1392357/d94c45f4.js
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_proxyPolicy_ssl_block]
+url = https://cn.bing.com/rs/31/22/cj,nj/3f1e2270/f8c6dd44.js
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_proxyPolicy_ssl_replace]
+url = https://cn.bing.com/rs/5j/1pF/cj,nj/2213d9b6/b50738ca.js
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_proxyPolicy_ssl_hijack]
+url = https://cn.bing.com/rs/31/2n/cj,nj/4c7364c5/40e1b425.js
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_proxyPolicy_ssl_insert]
+url = https://cn.bing.com/?FORM=BEHPTB
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_proxyPolicy_http_redirect]
+url = http://cn.bing.com/rs/2V/pE/cj,nj/b1392357/d94c45f4.js
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_proxyPolicy_http_block]
+url = http://cn.bing.com/rs/31/22/cj,nj/3f1e2270/f8c6dd44.js
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_proxyPolicy_http_replace]
+url = http://cn.bing.com/rs/5j/1pF/cj,nj/2213d9b6/b50738ca.js
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_proxyPolicy_http_hijack]
+url = http://cn.bing.com/rs/31/2n/cj,nj/4c7364c5/40e1b425.js
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_proxyPolicy_http_insert]
+url = http://cn.bing.com/?FORM=BEHPTB
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_https_con_traffic_1k]
+url = https://downloadfile.self-test.geedge.net/1k
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_https_con_traffic_4k]
+url = https://downloadfile.self-test.geedge.net/4k
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_https_con_traffic_16k]
+url = https://downloadfile.self-test.geedge.net/16k
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_https_con_traffic_64k]
+url = https://downloadfile.self-test.geedge.net/64k
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_https_con_traffic_256k]
+url = https://downloadfile.self-test.geedge.net/256k
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_https_con_traffic_1M]
+url = https://downloadfile.self-test.geedge.net/1M
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_https_con_traffic_4M]
+url = https://downloadfile.self-test.geedge.net/4M
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_https_con_traffic_16M]
+url = https://downloadfile.self-test.geedge.net/16M
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[test_https_con_traffic_64M]
+url = https://downloadfile.self-test.geedge.net/64M
+enabled = 1
+conn_timeout = 1
+max_recv_speed_large = 6553600
+
+[start_time_random_delay_range]
+enabled = 1
+#Left_edge is the left edge of the randomly generated time in seconds
+left_edge = 0
+#Left_edge is the right edge of the randomly generated time in seconds
+right_edge = 30
+
+[telegraf]
+host = 192.51.100.1
+port = 8100
+tags_key = app_name
+tags_value = tsg-diagnose
diff --git a/unittest_python/unittest/tsg_diagnose.conf b/unittest_python/unittest/tsg_diagnose.conf
deleted file mode 100644
index 58b4556..0000000
--- a/unittest_python/unittest/tsg_diagnose.conf
+++ /dev/null
@@ -1,120 +0,0 @@
-[test_securityPolicy_bypass]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_securityPolicy_intercept]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_securityPolicy_intercept_certerrExpired]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600
-
-# 50M bps
-
-[test_securityPolicy_intercept_certerrSelf_signed]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_securityPolicy_intercept_certerrUntrusted_root]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_proxyPolicy_ssl_redirect]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_proxyPolicy_ssl_block]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_proxyPolicy_ssl_replace]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_proxyPolicy_ssl_hijack]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_proxyPolicy_ssl_insert]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_proxyPolicy_http_redirect]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_proxyPolicy_http_block]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_proxyPolicy_http_replace]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_proxyPolicy_http_hijack]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_proxyPolicy_http_insert]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_https_con_traffic_1k]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_https_con_traffic_4k]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_https_con_traffic_16k]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_https_con_traffic_64k]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_https_con_traffic_256k]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_https_con_traffic_1M]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_https_con_traffic_4M]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-[test_https_con_traffic_16M]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps
-
-[test_https_con_traffic_64M]
-enabled = 1
-conn_timeout = 1
-max_recv_speed_large = 6553600 # 50M bps