]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
oeqa/runtime/connman: Drop unused test
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 18 Feb 2025 10:43:04 +0000 (10:43 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 18 Feb 2025 22:52:42 +0000 (22:52 +0000)
This test checks for an IP address and then tests if interface aliases work. We
don't run it on any of our automated testing as it only applies for non-qemu.

The connectivity test is unrealted to connman and pretty pointless as it depends
on ssh being working, so networking is probably ok.

The alias interface test is unrelated to commman and a general networking test
but seems out of place.

The code uses obsolete ifconfig calls and overall, the value of the test we're
never using seems low. Delete it.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/lib/oeqa/runtime/cases/ethernet_ip_connman.py

index eac8f2d082b5e345adf4fe75587ad9e0c69e15e3..4e671ec0ccd453a101457931c5c54b00603c41bc 100644 (file)
@@ -9,24 +9,6 @@ from oeqa.core.decorator.data import skipIfQemu
 
 class Ethernet_Test(OERuntimeTestCase):
 
-    def set_ip(self, x): 
-        x = x.split(".")
-        sample_host_address = '150'        
-        x[3] = sample_host_address
-        x = '.'.join(x)
-        return x
-    
-    @skipIfQemu()
-    @OETestDepends(['ssh.SSHTest.test_ssh'])
-    def test_set_virtual_ip(self):
-        (status, output) = self.target.run("ifconfig eth0 | grep 'inet ' | awk '{print $2}'")
-        self.assertEqual(status, 0, msg='Failed to get ip address. Make sure you have an ethernet connection on your device, output: %s' % output)
-        original_ip = output 
-        virtual_ip = self.set_ip(original_ip)
-        
-        (status, output) = self.target.run("ifconfig eth0:1 %s netmask 255.255.255.0 && sleep 2 && ping -c 5 %s && ifconfig eth0:1 down" % (virtual_ip,virtual_ip))
-        self.assertEqual(status, 0, msg='Failed to create virtual ip address, output: %s' % output)
-        
     @skipIfQemu()
     @OETestDepends(['ethernet_ip_connman.Ethernet_Test.test_set_virtual_ip'])  
     def test_get_ip_from_dhcp(self): 
@@ -39,4 +21,4 @@ class Ethernet_Test(OERuntimeTestCase):
         default_gateway = output
 
         (status, output) = self.target.run("connmanctl config %s --ipv4 dhcp && sleep 2 && ping -c 5 %s" % (wired_interfaces,default_gateway))
-        self.assertEqual(status, 0, msg='Failed to get dynamic IP address via DHCP in connmand, output: %s' % output)
\ No newline at end of file
+        self.assertEqual(status, 0, msg='Failed to get dynamic IP address via DHCP in connmand, output: %s' % output)