Skip to content

Feat/testcase duplication prevention#4277

Open
veenone wants to merge 2 commits intokiwitcms:masterfrom
veenone:feat/testcase-duplication-prevention
Open

Feat/testcase duplication prevention#4277
veenone wants to merge 2 commits intokiwitcms:masterfrom
veenone:feat/testcase-duplication-prevention

Conversation

@veenone
Copy link
Copy Markdown

@veenone veenone commented Feb 17, 2026

This PR is implementing additional checking on entry creation for :

  1. Test case
  2. Testplan
  3. Testrun

the PR implements #4111 , where current TCMS behavior allows testcase, testplan & testrun summary duplication.
this leads to confusion on them if multiple duplication exists in the entries.

this PR will provide the solution that can prevents duplicated entries to be created.


Screenshots

As the user type the entry, any duplicate entries will be displayed in the dropdown box to ensure user not to use them

chrome_9lfYB5Vu6V

The existing entry will be displayed if selected

chrome_2Rs4V3LCIr

- Debounced autocomplete dropdown on summary input showing existing
  test cases matching the typed text (case-insensitive, via
  summary__icontains), with clickable items that open a detail modal
- Block form submission when an exact case-insensitive duplicate
  exists (synchronous summary__iexact check on submit)
- Modal displays full test case details (summary, status, category,
  priority, author) with markdown-rendered description
- "View existing test case" button in modal header links to the
  duplicate TC detail page
- Inline warning below summary field when exact match is detected
- Only active on the New Test Case page (not Edit)
Extract shared initDuplicateCheck() utility into utils.js and
reusable modal template to avoid code duplication across modules.
Refactor test case mutable.js to use the shared utility.
Add duplicate name/summary check with autocomplete dropdown and
blocking modal to new test run and new test plan creation pages.
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