docs: Fix documentation inconsistencies in documentation/ folder#37394
Draft
docs: Fix documentation inconsistencies in documentation/ folder#37394
Conversation
Co-authored-by: timovv <1787642+timovv@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix documentation inconsistencies in documentation folder
docs: Fix documentation inconsistencies in documentation/ folder
Feb 27, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes several stale/incorrect patterns in the
documentation/folder that conflict with the current tooling and test framework used in this repo.Changes
Node.js version (
Quickstart-on-how-to-write-tests.md,Generate-code-from-TypeSpec.md): "LTS versions of Node.js" → "Node.js 20 or later" to matchpackage.jsonengines: { node: ">=20" }.Test examples updated to vitest (
Quickstart-on-how-to-write-tests.md): Bothglossary.spec.tsandmonitor.spec.tsdoc examples used outdated mocha/chai patterns:import { assert } from "chai"→import { ..., assert, ... } from "vitest"import { Context } from "mocha"removed; replaced withimport type { TestInfo } from "@azure-tools/test-recorder"new Recorder(context.currentTest)→new Recorder(context)beforeEach(async function (this: Context)→beforeEach(async (ctx) =>import type { RecorderStartOptions, TestInfo }.jsextensionsShell command fix (
resolve-pnpm-lock-merge-conflict.md): Missing/betweengit rev-parse --show-topleveloutput andpnpm-lock.yamlin the combined one-liner.Remove broken install command (
steps-after-generations.md): Removednpm install -g common/tools/dev-tool— a local-path global install that doesn't work.npx dev-toolon the next line is sufficient.Packages impacted by this PR
Documentation only — no package code changed.
Issues associated with this PR
N/A
Describe the problem that is addressed by this PR
Documentation examples referenced mocha/chai (removed from the repo in favor of vitest), used incorrect Node.js version requirements, had a broken shell command, and included a non-functional
npm install -ginvocation.What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
Straightforward corrections to match current repo conventions; no design alternatives.
Are there test cases added in this PR? (If not, why?)
No — documentation-only changes.
Provide a list of related PRs (if any)
N/A
Checklists
Original prompt
This section details on the original issue you should resolve
<issue_title>[docs] Fix documentation inconsistencies in documentation/ folder</issue_title>
<issue_description>## Summary
This PR fixes several inconsistencies found between the
documentation/folder and the actual source code/tooling in this repository.1. Node.js version requirement updated (
Quickstart-on-how-to-write-tests.md,Generate-code-from-TypeSpec.md)Issue: Both files said "Any/all of the LTS versions of Node.js" as a prerequisite.
Fix: Updated to "Node.js 20 or later" to match the
package.jsonenginesfield ("node": ">=20").2. Test examples updated from mocha/chai to vitest (
Quickstart-on-how-to-write-tests.md)Issue: The two test examples in the quickstart guide (
glossary.spec.tsandmonitor.spec.ts) used mocha/chai patterns that are no longer used in this repo:import { assert } from "chai"— the repo usesassertfromvitestimport { Context } from "mocha"— the repo usesTestInfofrom@azure-tools/test-recordernew Recorder(context.currentTest)— the vitest API isnew Recorder(context)(no.currentTest)beforeEach(async function (this: Context)— the vitest pattern isbeforeEach(async (ctx) =>import { Recorder, RecorderStartOptions }(non-type import) — should useimport typefor typesFix: Updated both examples to reflect current vitest patterns, consistent with actual test files such as
sdk/purview/purview-datamap-rest/test/public/glossary.spec.tsandsdk/monitor/arm-monitor/test/monitor.spec.ts.3. Fix missing
/in shell command (resolve-pnpm-lock-merge-conflict.md)Issue: The combined shell command at the bottom of the file had a missing
/separator between thegit rev-parse --show-topleveloutput andpnpm-lock.yaml:4. Remove incorrect
npm install -gcommand for dev-tool (steps-after-generations.md)Issue: The samples publishing instructions included
npm install -g common/tools/dev-tool— a local path global install that does not work and referencesnpminstead ofpnpm.Fix: Removed this line.
npx dev-tool(already on the next line) is sufficient and correct since@azure/dev-toolis available as adevDependencyin packages and via the pnpm workspace.To apply the patch locally:
Show patch preview (184 of 184 lines)