[TF] Fix issue with missing NetworkIpAvailability extension.

In environment with TungstenFabric and enabled amphora provider.

Related-PROD: PRODX-30528
Change-Id: I63c36c3c23d920f12f4823062990227844f2bf49
diff --git a/octavia_tempest_plugin/tests/test_base.py b/octavia_tempest_plugin/tests/test_base.py
index ead7167..79c8bf0 100644
--- a/octavia_tempest_plugin/tests/test_base.py
+++ b/octavia_tempest_plugin/tests/test_base.py
@@ -34,6 +34,7 @@
 
 from octavia_tempest_plugin.common import cert_utils
 from octavia_tempest_plugin.common import constants as const
+from octavia_tempest_plugin import config as config_octavia
 from octavia_tempest_plugin.tests import RBAC_tests
 from octavia_tempest_plugin.tests import validators
 from octavia_tempest_plugin.tests import waiters
@@ -861,7 +862,8 @@
         LOG.debug('Octavia Setup: webserver2_public_ip = {}'.format(
             cls.webserver2_public_ip))
 
-        if CONF.load_balancer.test_with_ipv6:
+        if (CONF.load_balancer.test_with_ipv6 and not
+                config_octavia.is_tungstenfabric_backend_enabled()):
             # Enable the IPv6 nic in webserver 1
             cls._enable_ipv6_nic_webserver(
                 cls.webserver1_public_ip, cls.lb_member_keypair['private_key'],
@@ -1041,9 +1043,24 @@
                 network_id=network['id'],
                 mac_address=instance_network[0]['OS-EXT-IPS-MAC:mac_addr'])
             port_id = result['ports'][0]['id']
-            result = cls.lb_mem_float_ip_client.create_floatingip(
-                floating_network_id=CONF.network.public_network_id,
-                port_id=port_id)
+            if config_octavia.is_tungstenfabric_backend_enabled():
+                port = result['ports'][0]
+                fixed_ip = None
+                for ip in port["fixed_ips"]:
+                    if (type(ipaddress.ip_address(ip["ip_address"])) is
+                            ipaddress.IPv4Address):
+                        fixed_ip = ip["ip_address"]
+                        break
+                assert fixed_ip is not None, (f"Port doesn't have ipv4 "
+                                              f"address: {port['fixed_ips']}")
+                result = cls.lb_mem_float_ip_client.create_floatingip(
+                    floating_network_id=CONF.network.public_network_id,
+                    port_id=port_id,
+                    fixed_ip_address=fixed_ip)
+            else:
+                result = cls.lb_mem_float_ip_client.create_floatingip(
+                    floating_network_id=CONF.network.public_network_id,
+                    port_id=port_id)
             floating_ip = result['floatingip']
             LOG.info('webserver1_floating_ip: {}'.format(floating_ip))
             cls.addClassResourceCleanup(