Skip to content

Inline edit test case ID and default ID sorting#43

Merged
joyzoursky merged 1 commit intomainfrom
test-case-id
Mar 10, 2026
Merged

Inline edit test case ID and default ID sorting#43
joyzoursky merged 1 commit intomainfrom
test-case-id

Conversation

@joyzoursky
Copy link
Copy Markdown
Collaborator

Summary

  • Add inline editing for test case ID directly from the Test Cases table ID column.
  • Keep Name column behavior as navigation to the run page.
  • Default Test Cases table sorting to ID ascending on initial load/reload.

Changes

  • src/app/projects/[id]/page.tsx
  • Added inline ID edit state and save flow (blur/Enter save, Escape cancel).
  • ID updates call PUT /api/test-cases/:id with preserveStatus: true.
  • Set default sortColumn to id and sortDirection to asc.
  • Kept Name column as link to /run?testCaseId=...&projectId=....
  • src/app/api/test-cases/[id]/route.ts
  • Added optional preserveStatus in PUT payload.
  • Preserve existing status when preserveStatus === true; otherwise keep existing behavior (status = DRAFT).

Validation

  • Lint/Typecheck/Audit: npm run verify passed.
  • Manual: not run.

Breaking Changes

  • None.

Risks

  • The preserveStatus flag relies on caller intent; future callers should set it explicitly only for metadata-only updates.

Follow-ups

  • Add API-level tests for preserveStatus PUT behavior.
  • Add UI test coverage for inline ID edit interactions.

@joyzoursky joyzoursky changed the title feat(project): inline edit test case ID and default ID sorting Inline edit test case ID and default ID sorting Mar 10, 2026
@joyzoursky joyzoursky merged commit 9db0819 into main Mar 10, 2026
1 check passed
@joyzoursky joyzoursky deleted the test-case-id branch March 10, 2026 09:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant