]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
test/py: Detect timeout in phy negotiation
authorMichal Simek <michal.simek@xilinx.com>
Fri, 29 Apr 2016 11:53:37 +0000 (13:53 +0200)
committerMichal Simek <michal.simek@xilinx.com>
Fri, 15 Jul 2016 07:04:58 +0000 (09:04 +0200)
If timeout happen it should be reported as fault.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Acked-by: Stephen Warren <swarren@nvidia.com>
test/py/tests/test_net.py

index 100ff73454781aaa4c91815a4e9f557297dfd45e..21e50897da42338f8228bbca7a57abdd264798cf 100644 (file)
@@ -81,6 +81,7 @@ def test_net_dhcp(u_boot_console):
 
     u_boot_console.run_command('setenv autoload no')
     output = u_boot_console.run_command('dhcp')
+    assert 'TIMEOUT' not in output
     assert 'DHCP client bound to address ' in output
 
     global net_set_up
@@ -117,6 +118,7 @@ def test_net_ping(u_boot_console):
         pytest.skip('Network not initialized')
 
     output = u_boot_console.run_command('ping $serverip')
+    assert 'TIMEOUT' not in output
     assert 'is alive' in output
 
 @pytest.mark.buildconfigspec('cmd_net')
@@ -151,6 +153,7 @@ def test_net_tftpboot(u_boot_console):
     sz = f.get('size', None)
     if sz:
         expected_text += '%d' % sz
+    assert 'TIMEOUT' not in output
     assert expected_text in output
 
     expected_crc = f.get('crc32', None)