11import copy
22import ipaddress
3- from test .integration .helpers import (
4- get_test_label ,
5- wait_for_condition ,
6- )
3+ import os
4+ from test .integration .helpers import get_test_label , wait_for_condition
75
86import pytest
97
@@ -498,18 +496,45 @@ def test_linode_interfaces_with_reserved_ips(
498496 assert reserved_ips_list [0 ].assigned_entity is None
499497
500498
501- @pytest .mark .skip (
502- reason = "Linode with RDMA interfaces requires manual infra changes at the moment"
499+ @pytest .mark .skipif (
500+ os .getenv ("RUN_RDMA_TESTS" , "" ).strip ().lower () not in {"yes" , "true" },
501+ reason = "Linode with RDMA interfaces requires manual infra changes; set RUN_RDMA_TESTS=yes to enable" ,
503502)
504503def test_linode_interfaces_with_rdma_vpc_type (
505504 request ,
506505 test_linode_client ,
507- create_vpc_with_subnet ,
508- create_vpc_with_subnet_and_rdma_type ,
509506):
510507 client = test_linode_client
511- vpc , subnet = create_vpc_with_subnet
512- vpc_rdma , subnet_rdma = create_vpc_with_subnet_and_rdma_type
508+ region = "us-rno-1"
509+
510+ # Create a regular VPC with a subnet in us-rno-1
511+ vpc = client .vpcs .create (
512+ label = get_test_label (length = 10 ),
513+ region = region ,
514+ description = "test description" ,
515+ ipv6 = [{"range" : "auto" }],
516+ )
517+ request .addfinalizer (vpc .delete )
518+ subnet = vpc .subnet_create (
519+ label = "test-subnet" ,
520+ ipv4 = "10.0.0.0/24" ,
521+ ipv6 = [{"range" : "auto" }],
522+ )
523+ request .addfinalizer (subnet .delete )
524+
525+ # Create an RDMA VPC with a subnet in us-rno-1
526+ vpc_rdma = client .vpcs .create (
527+ label = get_test_label (length = 10 ),
528+ region = region ,
529+ description = "test description" ,
530+ vpc_type = "rdma" ,
531+ )
532+ request .addfinalizer (vpc_rdma .delete )
533+ subnet_rdma = vpc_rdma .subnet_create (
534+ label = get_test_label (length = 10 ),
535+ ipv4 = "10.0.0.0/24" ,
536+ )
537+ request .addfinalizer (subnet_rdma .delete )
513538
514539 # Include RDMA VPC interfaces
515540 multi_ifaces = create_multiple_rdma_interfaces (8 , subnet_rdma .id )
@@ -536,19 +561,19 @@ def test_linode_interfaces_with_rdma_vpc_type(
536561 )
537562
538563 instance = client .linode .instance_create (
539- label = "go -test-rdma-" + get_test_label (),
564+ label = "python -test-rdma-" + get_test_label (),
540565 root_pass = "aComplex@Password123" ,
541566 image = "linode/ubuntu24.04" ,
542567 region = vpc .region ,
543- # ltype="TBD",
544- # host_id="TBD",
568+ ltype = "g3-gpu-rtxpro6000-blackwell-rdma-8" ,
545569 interface_generation = InterfaceGeneration .LINODE ,
546570 interfaces = multi_ifaces ,
547571 booted = False ,
548572 )
549573 request .addfinalizer (instance .delete )
550574
551575 def get_linode_status ():
576+ instance .invalidate ()
552577 return instance .status == "offline"
553578
554579 wait_for_condition (5 , 180 , get_linode_status )
0 commit comments