app icon indicating copy to clipboard operation
app copied to clipboard

Make describe block configurable to not be displayed as a separate test suit

Open dmrock opened this issue 1 year ago • 7 comments

Is your feature request related to a problem? Please describe. E2E Tests / Playwright

When I import the Playwright project to Testomat, it displays each describe block as a separate test suit, which makes the whole project a bit messy. I can fix it by adding some context to describe title, but that will make titles in the HTML report repeatable.

Describe the solution you'd like I'd like to have an option to keep describe blocks inside the spec files.

Describe alternatives you've considered Maybe I can move the describe suits manually, but I'm not sure if it will be reset on re-sync.

Additional context Here is an example, where I'd like to keep describes inside the spec file: image

dmrock avatar Mar 04 '24 15:03 dmrock

The issue has been verified and confirmed as fixed. describe blocks are no longer displayed as separate suites; they now remain nested under their respective spec files. The structure stays stable after re-sync, and test IDs are preserved. The functionality works as expected in the latest release under milestone #42.

AZANIR avatar Oct 28 '25 11:10 AZANIR

Hey @AZANIR, thanks for the update. I'm not sure you linked the issue to the correct milestone, the link leads to sth related to onboarding. Just to be sure, is this already released?

dmrock avatar Oct 28 '25 11:10 dmrock

@dmrock it's already released

TetianaKhomenko avatar Oct 28 '25 11:10 TetianaKhomenko

@TetianaKhomenko, on my end, it's still mixed up:

Image

I have the latest version of testomatio/reporter installed, and I recently updated test IDs via this script:

"npx check-tests@latest Playwright '**/*{.,_}{test,spec,cy}.ts' --typescript --no-empty --update-ids --keep-structure --exclude '**/preflight.spec.ts'"

Is there anything else I should do to get this new feature working?

dmrock avatar Oct 28 '25 12:10 dmrock

@AZANIR please take a look

TetianaKhomenko avatar Oct 28 '25 12:10 TetianaKhomenko

@dmrock We re-checked the behavior on a clean project using check-tests v0.14.1 and the same import command:

npx check-tests@latest Playwright "/*{.,_}{test,spec,cy}.ts" --typescript --no-empty --update-ids --keep-structure --exclude "/preflight.spec.ts"

✅ The structure now works correctly:

All 7 tests are parsed and displayed.

Nested describe blocks remain inside their spec files and appear properly in the Suites tree (Nested Describe A/B, Profile Editing, etc.).

The overall hierarchy and test counters are accurate and stable after sync.

⚙️ Note: If you still see mixed or duplicated suites (each describe as a separate suite), please remove the existing tests in your Testomat project and re-import them using the command above. This will reset the outdated structure and apply the new correct behavior — the result will look exactly like on the attached screenshot.

📎 Attaching screenshots that confirm the correct nested describe display and structure.

Image Image

AZANIR avatar Oct 28 '25 14:10 AZANIR

I can't confirm the fix. I've reimported tests from scratch, and here is how it looks:

Image

dmrock avatar Oct 30 '25 08:10 dmrock