TPT-4463: Add integration tests for RDMA interfaces#999
Conversation
* TPT-4423: Drop resty as a dependency (linode#938) * Ported resty removal changes to new branch from up-to-date main and made additional changes to monitor client * Fixed lint * Updated log formatting to more closely resemble Resty's * Fixed lint * redact request header log * Fixes * Fixed CoPilot suggestions * Sanitize log output * Addressed CoPilot comments --------- Co-authored-by: Zhiwei Liang <zliang@akamai.com> * TPT-4421: Remove deprecated fields and methods (linode#946) * Removed deprecated fields and methods and updated tests * Fix lint * Addressed copilot suggestion * Fixed lint * Removed V2 suffix from various fields and methods * Addressed CoPilot suggestions * Added separate struct for Instance IP Address update options * Address PR suggestions * TPT-4414: Refactor JSON tags to use "omitzero" for optional fields across multiple files (linode#947) * Refactor JSON struct tags to use "omitzero" for optional fields * Remove url tags in pagination structs * TPT-4414: Change slice pointer types with `omitzero` to be slice (linode#954) * Refactor: Change pointer slices to slices for various fields with omitzero * Refresh fixtures * Update TestLKECluster_Update to remove pinned lke versions in test * TPT-4434: Added custom type for Region Capabilities and updated tests (linode#953) * Added custom type for Region Capabilities and updated tests * Fix formatting * Added disctinction between Object Storage Bucket Access POST/PUT endpoints (linode#951) * TPT-3454: Refactor wait functions to use context for timeouts and polling (linode#964) * Refactor wait functions to use context for timeouts and polling * fix context cancelled in cleanup * nolint generic return type * Fix grammar Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Make preTask a private function; cleanup unnecessary previousEvents allocation * Fix error msg format Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * TPT-4422: Added options structs for POST/PUT endpoints that were missing them (linode#968) * Added options structs for POST/PUT endpoints that were missing them * Address PR comments * Address PR comments * TPT-3483: Update NewClient method to return an error rather than just logging errors (linode#967) * refactor: update NewClient and related functions to handle errors properly * refactor: update SetRootCertificate to return errors and enhance logging * update NewClient instantiation to handle errors * Export PaginatedResponse type in request_helpers (linode#970) * TPT-3388: Separated GET and POST/PUT options structs where needed (linode#969) * Separated GET and POST/PUT options structs where needed * Separated additional structs that were reused for options and response * More struct fixes * Fix lint * Rename FirewallRule structs * integration test fixes * Addressed PR comments * FirewallRuleSetRule options; test updates; fixture refreshed * Address more PR comments --------- Co-authored-by: Zhiwei Liang <zliang@akamai.com> * TPT-4464: Update FirewallDeviceEntity Label field to be a pointer (linode#971) * Update FirewallDeviceEntity Label field to be a pointer and adjust tests accordingly * Fix unit tests * fmt * Fix another unit test * Change `[]*T` to `[]T` in all structs (linode#972) * Remove LKE cluster dashboard function, tests, and related fixture (linode#975) * Simplify client.go (linode#976) Signed-off-by: Zhiwei Liang <zhiwei.liang@zliang.me> * Apply suggestion from @zliang-akamai * Update region capability in TestImageSharing_Suite to use Linodes --------- Signed-off-by: Zhiwei Liang <zhiwei.liang@zliang.me> Co-authored-by: Erik Zilber <ezilber@akamai.com> Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> Co-authored-by: Zhiwei Liang <zhiwei.liang@zliang.me>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
…e#962) Bumps [actions/dependency-review-action](https://github.com/actions/dependency-review-action) from 4 to 5. - [Release notes](https://github.com/actions/dependency-review-action/releases) - [Commits](actions/dependency-review-action@v4...v5) --- updated-dependencies: - dependency-name: actions/dependency-review-action dependency-version: '5' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [golang.org/x/net](https://github.com/golang/net) from 0.54.0 to 0.55.0. - [Commits](golang/net@v0.54.0...v0.55.0) --- updated-dependencies: - dependency-name: golang.org/x/net dependency-version: 0.55.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* build(deps): bump k8s.io/client-go from 0.29.4 to 0.36.1 Bumps [k8s.io/client-go](https://github.com/kubernetes/client-go) from 0.29.4 to 0.36.1. - [Changelog](https://github.com/kubernetes/client-go/blob/master/CHANGELOG.md) - [Commits](kubernetes/client-go@v0.29.4...v0.36.1) --- updated-dependencies: - dependency-name: k8s.io/client-go dependency-version: 0.36.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * Downgrade to v0.35.5 --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Zhiwei Liang <zliang@akamai.com>
* Add AGENTS.md documentation for repo structure, commands, and conventions * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Maciej Wilk <mawilk@akamai.com>
* docs: add migration guide for linodego v2 * Apply suggestions from code review Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
* LKE Node Pools: add isolation and disk encryption options * LKE Cluster: add RuleSetIDs for enterprise cluster creation with tests * Add Version field to Firewall and FirewallRuleSet structs with test coverage * Add GetPrefixListByName helper with test coverage * Build fix and format * Fix JSON omitzero tag for LKENodePoolIsolation field * Add LKENodePoolIsolationCreateOptions and LKENodePoolIsolationUpdateOptions for network isolation * Clarify JSON omitzero usage for optional fields in create and update options structs * Remove LKECluster RuleSetIDs and Firewall Version fields * Deep clean of firewall version and cluster rules set things * Apply suggestions from code review Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Add isolation options to node pool create and update fixtures; update tests accordingly * Apply suggestions from code review Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Add availability notes * Remove isolation options from LKENodePool update options and related tests --------- Co-authored-by: Zhiwei Liang <121905282+zliang-akamai@users.noreply.github.com> Co-authored-by: Zhiwei Liang <zliang@akamai.com> Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
* Update domain name in setupDomain func to be unique * Fix TestAccountEvents_List_smoke, setupLKECluster, createPostgresDatabase, TestVolume_Create_smoke # Conflicts: # test/integration/lke_clusters_test.go # test/integration/volumes_test.go * Update tags for linode-tpt and add IPv6 range in TestLKECluster_Enterprise_BYOVPC_smoke * Address Copilot remarks * Add waits and skip to smoke tests * Add dynamic waits and re-run fixtures * Revert changes in TestObjectStorageQuotas_ tests done in linode#980 * Fix TestObjectStorageQuotaUsage_Get * Address Copilot remarks * Remove t.Skip from TestMonitorDashboards_Get_smoke as linode#979 solved the issue * Update fixture for TestMonitorDashboards_Get_smoke * Add getExistingObjectStorageQuotaID to retrieve account-specific quota objects * Address PR remarks
…IPv4 (linode#945) * TPT-4277 Implement support for Reserved IP for IPv4 * Refactor existing tests for ReservedIPs - replace hardcoded regions with getRegionsWithCaps - skip tests that will fail on DevCloud * Update fixtures for existing ReservedIPs tests * Add assertions for ReservedIPs in existing tests * Add assertions for ReservedIP Tags * Add test for Tag with ReservedIP * Linter & fixtures fixes * Extend assertions in TestTag_CreateTagWithReservedIP * Regenerate fixtures after merge with proj/reserved-ips * Remove redundant unit tests added accidentally during rebase --------- Co-authored-by: Michal Wojcik <miwojci@akamai.com>
TPT-4275: IP Reservation (IPv4) Project
…g warning for unsupported transports (linode#995) * Check transport type before setting root certificate and log warning for unsupported transports * golangci-lint fmt * update test and ignore lint * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
* [DPS-42278] added support for log destinations api + unit tests * [DPS-42278] integration tests + review tweaks * [DPS-42278] review tweaks * [DPS-42278] removed time fields hack + updated fixtures + resolved issue with always serialized storage key and secret - now test logs destination tests will always pass also in recording mode * [DPS-42278] more tests tweaks + new api changes * [DPS-42278] added support for custom https destination type * [DPS-42279] [ACLP SDK] [Go] ACLP Logs stream API * [DPS-42279] [ACLP SDK] [Go] ACLP Logs stream API - fixtures and fixes * [DPS-42279] [ACLP SDK] [Go] ACLP Logs stream API - log destinations api.linode fixtures * [DPS-42279] [ACLP SDK] [Go] ACLP Logs stream API - regenerated fixtures * [DPS-42279] [ACLP SDK] [Go] ACLP Logs stream API - regenerated fixtures * [DPS-42279] [ACLP SDK] [Go] ACLP Logs stream API - fix * [DPS-42279] [ACLP SDK] [Go] ACLP Logs stream API - fixes regarding PR comments * [DPS-42654] [ACLP SDK][Go] ACLP Logs SDK Pull request - added github event input run_aclp_logs_stream_tests * [DPS-42654] [ACLP SDK][Go] ACLP Logs SDK Pull request - added github event input run_aclp_logs_stream_tests to integration tests pr yaml * [DPS-42654] [ACLP SDK][Go] ACLP Logs SDK Pull request - fixed issues from PR comments, regenerated sanitized fixtures * [DPS-42654] [ACLP SDK][Go] ACLP Logs SDK Pull request - fixed lint errors * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * [DPS-42654] [ACLP SDK][Go] ACLP Logs SDK Pull request - lint errors * [DPS-42654] [ACLP SDK][Go] ACLP Logs SDK Pull request - minor fixes * [DPS-42654] [ACLP SDK][Go] ACLP Logs SDK Pull request - minor fixes * [DPS-42654] [ACLP SDK][Go] ACLP Logs SDK Pull request - workflow fixes * [DPS-42654] [ACLP SDK][Go] ACLP Logs SDK Pull request - workflow fixes * [DPS-42654] [ACLP SDK][Go] ACLP Logs SDK Pull request - workflow fixes --------- Co-authored-by: akrzyszt <akrzyszt@akamai.com> Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> Co-authored-by: Ye Chen <127243817+yec-akamai@users.noreply.github.com>
…g APIs (linode#985) * feat: add aclp clone api and group_by field * ref: replace error handling assertions
Current implementation of vpcCreateOptionsCheck verifies fields copied from VPC so comparing opts.Label == vpc.Label etc. is just comparing a value to itself —> good is always true.
There was a problem hiding this comment.
Pull request overview
This PR extends the Linode Go client’s VPC + interface models to represent RDMA-capable VPCs/interfaces and adds unit + integration coverage (plus fixtures) to validate (un)marshalling and key RDMA workflows. It’s intended to pair with the feature work in #988 and adds the test/fixture layer around that functionality.
Changes:
- Add
VPCType(regular/rdma) to VPC and VPC subnet models and wire it into VPC create options. - Add RDMA VPC interface models/options plus a new instance-create interface option type that supports RDMA VPC interfaces, with
InstanceCreateOptionsmarshaling support. - Add unit tests + integration tests + VCR fixtures for RDMA VPCs and RDMA interfaces.
Reviewed changes
Copilot reviewed 26 out of 26 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| vpc.go | Introduces VPCType and adds vpc_type support to VPC and create options. |
| vpc_subnet.go | Adds vpc_type to VPC subnet responses. |
| interfaces.go | Adds RDMA VPC interface models/options and instance-create interface option type. |
| instances.go | Adds LinodeInstanceInterfaces and extends InstanceCreateOptions.MarshalJSON conflict + serialization logic. |
| test/unit/rdma_vpc_test.go | Unit coverage for RDMA VPC type, RDMA interface (get/list/update), and marshaling semantics. |
| test/unit/fixtures/vpc_rdma_get.json | Unit fixture for RDMA VPC GET response. |
| test/unit/fixtures/vpc_rdma_create.json | Unit fixture for RDMA VPC create response/validation. |
| test/unit/fixtures/interface_update_rdma_vpc.json | Unit fixture for RDMA interface update response. |
| test/unit/fixtures/interface_list_with_rdma.json | Unit fixture for listing interfaces including RDMA entries. |
| test/unit/fixtures/interface_get_rdma_vpc.json | Unit fixture for RDMA interface GET response. |
| test/integration/vpc_test.go | Integration test refactor + adds RDMA VPC create/get/list filter coverage. |
| test/integration/vpc_subnet_test.go | Integration coverage for subnet vpc_type and RDMA subnet workflows. |
| test/integration/lke_clusters_test.go | Updates helper return signature usage due to createVPC refactor. |
| test/integration/instance_interfaces_test.go | Switches instance-create tests to LinodeInstanceInterfaces and adds RDMA interface integration test. |
| test/integration/fixtures/TestVPC_CreateGet.yaml | Updates recorded interactions to include vpc_type and devcloud URLs. |
| test/integration/fixtures/TestVPC_Create_Invalid.yaml | Updates recorded invalid-label interaction and message. |
| test/integration/fixtures/TestInstance_CreateWithLinodeInterfaces.yaml | Updates recorded instance-create interaction for updated VPC/subnet responses and devcloud URLs. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…ts-for-rdma-interfaces
|
Let me update the base branch and see if it fixes the workflow issues and clean up the git history |
|
There are a few things not compatible from merging v2. I've put up a PR to address them: #1003 After it merged you should be good to rebase from the proj branch into your branch to clean up the commit history. Although it's probably some conflicts to fix. I wonder if it's easier to check out a brand new branch though. |
|
@mawilk90 and @yec-akamai, how about rebase of |
📝 Description
Integration tests for RDMA interfaces
Notes:
mainso to minimize amount of "Files changed" target branch needs to be sync withmainas well.✔️ How to Test
Some local setup is needed before RDMA tests run.
RDMA integration tests:
make fixtures TEST_ARGS="-run TestVPC_WithRDMAType"make fixtures TEST_ARGS="-run TestVPC_Subnet_WithRDMAType"make fixtures TEST_ARGS="-run TestInstance_CreateWithRDMAVPCInterfaces"<- commented out as it requires manual infra setup at the momentRelated fixes and refactors:
DevCloud:
make test-int TEST_ARGS="-run TestVPC_CreateGet_smoke"make test-int TEST_ARGS="-run TestVPC_Subnet_Create"Prod:
make test-int TEST_ARGS="-run TestVPC_List"make test-int TEST_ARGS="-run TestVPC_Update"make test-int TEST_ARGS="-run TestVPC_Create_Invalid_data"make test-int TEST_ARGS="-run TestVPC_Update_Invalid"make test-int TEST_ARGS="-run TestVPC_Subnet_Create_Invalid_data"make test-int TEST_ARGS="-run TestVPC_Subnet_Update_Invalid_data"make test-int TEST_ARGS="-run TestLKECluster_Enterprise_BYOVPC_smoke"