Skip to content

[python] Add PUT test coverage for XML ModelWithDatetime scenario#10035

Merged
msyyc merged 3 commits intomainfrom
copilot/add-test-case-for-pull-9995
Mar 16, 2026
Merged

[python] Add PUT test coverage for XML ModelWithDatetime scenario#10035
msyyc merged 3 commits intomainfrom
copilot/add-test-case-for-pull-9995

Conversation

Copy link
Contributor

Copilot AI commented Mar 16, 2026

The test_model_with_datetime test only covered GET but was missing the PUT operation — the only XML payload test without round-trip coverage. PR #9995 fixed the Spector server to accept both 2022-08-26T18:38:00.000Z and 2022-08-26T18:38:00Z forms, unblocking the PUT test.

  • Test changes: Added client.model_with_datetime_value.put(model) to both sync and async test_model_with_datetime tests in generic_mock_api_tests/
  • Dependency bump: @typespec/http-specs0.1.0-alpha.35-dev.1, @typespec/spec-api0.1.0-alpha.14-dev.1 (includes the server-side datetime validation fix)
Original prompt

This section details on the original issue you should resolve

<issue_title>[python] add test case for #9995
</issue_title>
<issue_description>follow skill https://github.com/microsoft/typespec/blob/main/.github/skills/python-sdk-spector-mock-api-tests/SKILL.md to write test case for #9995
</issue_description>

Comments on the Issue (you are @copilot in this section)


💬 Send tasks to Copilot coding agent from Slack and Teams to turn conversations into code. Copilot posts an update in your thread when it's finished.

…ec-api deps

Co-authored-by: msyyc <70930885+msyyc@users.noreply.github.com>
@microsoft-github-policy-service microsoft-github-policy-service bot added the emitter:client:python Issue for the Python client emitter: @typespec/http-client-python label Mar 16, 2026
Copilot AI changed the title [WIP] [python] Add test case for pull 9995 [python] Add PUT test coverage for XML ModelWithDatetime scenario Mar 16, 2026
Copilot AI requested a review from msyyc March 16, 2026 03:13
@msyyc msyyc marked this pull request as ready for review March 16, 2026 05:03
@msyyc msyyc enabled auto-merge March 16, 2026 05:23
@azure-sdk
Copy link
Collaborator

You can try these changes here

🛝 Playground 🌐 Website 🛝 VSCode Extension

@pkg-pr-new
Copy link

pkg-pr-new bot commented Mar 16, 2026

Open in StackBlitz

npm i https://pkg.pr.new/@typespec/http-client-python@10035

commit: 75db2ce

@github-actions
Copy link
Contributor

All changed packages have been documented.

  • @typespec/http-client-python
Show changes

@typespec/http-client-python - internal ✏️

Add PUT test coverage for ModelWithDatetime XML payload scenario and bump @typespec/http-specs/@typespec/spec-api dependencies to include the datetime validation fix from PR #9995.

@msyyc msyyc added this pull request to the merge queue Mar 16, 2026
Merged via the queue into main with commit 40ec201 Mar 16, 2026
27 checks passed
@msyyc msyyc deleted the copilot/add-test-case-for-pull-9995 branch March 16, 2026 08:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

emitter:client:python Issue for the Python client emitter: @typespec/http-client-python

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[python] add test case for https://github.com/microsoft/typespec/pull/9995

4 participants