From 384052d7f7b62c1ce9da0fd597bc29c8c13ed5ca Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 19 Aug 2026 05:59:32 +0000 Subject: [PATCH 1/2] Initial plan From 2e00cdc08aa219a8b1fe75eb0c333e46f47868bf Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 19 Aug 2026 06:04:56 +0000 Subject: [PATCH 2/2] test(python): add operation templates paging nextLink coverage Co-authored-by: msyyc <70930885+msyyc@users.noreply.github.com> --- ...-arm-operationtemplates-nextlink-2026-8-19-6-0-0.md | 7 +++++++ packages/http-client-python/package-lock.json | 10 +++++----- packages/http-client-python/package.json | 2 +- .../test_azure_arm_operationtemplates_async.py | 3 +++ .../azure/test_azure_arm_operationtemplates.py | 3 +++ 5 files changed, 19 insertions(+), 6 deletions(-) create mode 100644 .chronus/changes/python-spector-tests-arm-operationtemplates-nextlink-2026-8-19-6-0-0.md diff --git a/.chronus/changes/python-spector-tests-arm-operationtemplates-nextlink-2026-8-19-6-0-0.md b/.chronus/changes/python-spector-tests-arm-operationtemplates-nextlink-2026-8-19-6-0-0.md new file mode 100644 index 00000000000..41f885113d2 --- /dev/null +++ b/.chronus/changes/python-spector-tests-arm-operationtemplates-nextlink-2026-8-19-6-0-0.md @@ -0,0 +1,7 @@ +--- +changeKind: internal +packages: + - "@typespec/http-client-python" +--- + +Add sync and async mock API coverage for ARM operation templates POST action paging to validate nextLink pagination across pages. diff --git a/packages/http-client-python/package-lock.json b/packages/http-client-python/package-lock.json index 64e2b328755..0245d43106c 100644 --- a/packages/http-client-python/package-lock.json +++ b/packages/http-client-python/package-lock.json @@ -17,7 +17,7 @@ "tsx": "^4.21.0" }, "devDependencies": { - "@azure-tools/azure-http-specs": "0.1.0-alpha.44", + "@azure-tools/azure-http-specs": "0.1.0-alpha.45-dev.3", "@azure-tools/typespec-autorest": "~0.71.0", "@azure-tools/typespec-azure-core": "~0.71.0", "@azure-tools/typespec-azure-resource-manager": "~0.71.0", @@ -67,9 +67,9 @@ } }, "node_modules/@azure-tools/azure-http-specs": { - "version": "0.1.0-alpha.44", - "resolved": "https://pkgs.dev.azure.com/azure-sdk/public/_packaging/azure-sdk-for-js/npm/registry/@azure-tools/azure-http-specs/-/azure-http-specs-0.1.0-alpha.44.tgz", - "integrity": "sha1-IAFFxVwqqbiWlgWOXHQAHiae8bk=", + "version": "0.1.0-alpha.45-dev.3", + "resolved": "https://registry.npmjs.org/@azure-tools/azure-http-specs/-/azure-http-specs-0.1.0-alpha.45-dev.3.tgz", + "integrity": "sha512-ih2/nxeDOaCsG/zXQOaNb5tr2cGm6CXDojk40ebcO4Tof2h9w1sBkflUIYIBiBMbrmsphU67R8ASAWLtjU02xQ==", "dev": true, "license": "MIT", "dependencies": { @@ -80,7 +80,7 @@ "node": ">=22.0.0" }, "peerDependencies": { - "@azure-tools/typespec-azure-core": "^0.71.0", + "@azure-tools/typespec-azure-core": "^0.71.0 || >= 0.72.0-dev.0", "@typespec/compiler": "^1.15.0", "@typespec/http": "^1.15.0", "@typespec/rest": "^0.85.0", diff --git a/packages/http-client-python/package.json b/packages/http-client-python/package.json index b530962f347..7631386c3cd 100644 --- a/packages/http-client-python/package.json +++ b/packages/http-client-python/package.json @@ -109,7 +109,7 @@ "@azure-tools/typespec-azure-resource-manager": "~0.71.0", "@azure-tools/typespec-azure-rulesets": "~0.71.0", "@azure-tools/typespec-client-generator-core": "~0.71.0", - "@azure-tools/azure-http-specs": "0.1.0-alpha.44", + "@azure-tools/azure-http-specs": "0.1.0-alpha.45-dev.3", "@typespec/compiler": "^1.15.0", "@typespec/http": "^1.15.0", "@typespec/openapi": "^1.15.0", diff --git a/packages/http-client-python/tests/mock_api/azure/asynctests/test_azure_arm_operationtemplates_async.py b/packages/http-client-python/tests/mock_api/azure/asynctests/test_azure_arm_operationtemplates_async.py index 4881c77f1c9..ae99e832a0c 100644 --- a/packages/http-client-python/tests/mock_api/azure/asynctests/test_azure_arm_operationtemplates_async.py +++ b/packages/http-client-python/tests/mock_api/azure/asynctests/test_azure_arm_operationtemplates_async.py @@ -244,8 +244,11 @@ async def test_paging_post_action_paging(client): body=models.LogStatusRequest(filter="status eq 'active'"), ) items = [item async for item in result] + assert len(items) == 2 assert items[0].id.endswith("/Microsoft.Compute/virtualMachines/vm1") assert items[0].sending_metrics == True + assert items[1].id.endswith("/Microsoft.Compute/virtualMachines/vm2") + assert items[1].sending_metrics == False @pytest.mark.asyncio diff --git a/packages/http-client-python/tests/mock_api/azure/test_azure_arm_operationtemplates.py b/packages/http-client-python/tests/mock_api/azure/test_azure_arm_operationtemplates.py index b7c92737fef..4b1234ee81f 100644 --- a/packages/http-client-python/tests/mock_api/azure/test_azure_arm_operationtemplates.py +++ b/packages/http-client-python/tests/mock_api/azure/test_azure_arm_operationtemplates.py @@ -213,8 +213,11 @@ def test_paging_post_action_paging(client): body=models.LogStatusRequest(filter="status eq 'active'"), ) items = list(result) + assert len(items) == 2 assert items[0].id.endswith("/Microsoft.Compute/virtualMachines/vm1") assert items[0].sending_metrics == True + assert items[1].id.endswith("/Microsoft.Compute/virtualMachines/vm2") + assert items[1].sending_metrics == False def test_paging_mark_as_pageable(client):