]> granicus.if.org Git - esp-idf/commitdiff
test: collect example https_request binary size
authorHe Yin Ling <heyinling@espressif.com>
Sat, 11 Nov 2017 07:17:00 +0000 (15:17 +0800)
committerHe Yin Ling <heyinling@espressif.com>
Thu, 16 Nov 2017 09:48:30 +0000 (17:48 +0800)
examples/protocols/https_request/example_test.py

index b58bdae852abd2bf6cd47988292d2f7e189c7f47..61eb024532c28baa17a9de310693b9dd70176f23 100644 (file)
@@ -23,6 +23,12 @@ def test_examples_protocol_https_request(env, extra_data):
       3. send http request
     """
     dut1 = env.get_dut("https_request", "examples/protocols/https_request")
+    # check and log bin size
+    binary_file = os.path.join(dut1.app.binary_path, "https-request.bin")
+    bin_size = os.path.getsize(binary_file)
+    IDF.log_performance("https_request_bin_size", "{}KB".format(bin_size//1024))
+    IDF.check_performance("https_request_bin_size", bin_size//1024)
+    # start test
     dut1.start_app()
     dut1.expect("Connecting to www.howsmyssl.com:443", timeout=30)
     dut1.expect("Performing the SSL/TLS handshake")