mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-09 12:35:28 +00:00
CI: input ssid password depends on sdkconfig
This commit is contained in:
@@ -55,11 +55,6 @@ def test_examples_protocol_socket_tcpserver(env, extra_data):
|
||||
2. have the board connect to the server
|
||||
3. send and receive data
|
||||
"""
|
||||
# get env config
|
||||
env_config = get_env_config('wifi_router')
|
||||
ap_ssid = env_config['ap_ssid']
|
||||
ap_password = env_config['ap_password']
|
||||
|
||||
dut1 = env.get_dut('tcp_client', 'examples/protocols/sockets/tcp_server', dut_class=ttfw_idf.ESP32DUT)
|
||||
# check and log bin size
|
||||
binary_file = os.path.join(dut1.app.binary_path, 'tcp_server.bin')
|
||||
@@ -68,8 +63,12 @@ def test_examples_protocol_socket_tcpserver(env, extra_data):
|
||||
|
||||
# start test
|
||||
dut1.start_app()
|
||||
dut1.expect('Please input ssid password:')
|
||||
dut1.write(' '.join([ap_ssid, ap_password]))
|
||||
if dut1.app.get_sdkconfig_config_value('CONFIG_EXAMPLE_WIFI_SSID_PWD_FROM_STDIN'):
|
||||
env_config = get_env_config('wifi_router')
|
||||
ap_ssid = env_config['ap_ssid']
|
||||
ap_password = env_config['ap_password']
|
||||
dut1.expect('Please input ssid password:')
|
||||
dut1.write(' '.join([ap_ssid, ap_password]))
|
||||
|
||||
ipv4 = dut1.expect(re.compile(r' IPv4 address: ([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)'), timeout=30)[0]
|
||||
ipv6_r = r':'.join((r'[0-9a-fA-F]{4}',) * 8) # expect all 8 octets from IPv6 (assumes it's printed in the long form)
|
||||
|
Reference in New Issue
Block a user