Skip to content

test: adjust WedDav preview test case for Devanagari script [full-ci]#41672

Merged
phil-davis merged 1 commit into
masterfrom
test-fix-previews-feature-211
Jul 9, 2026
Merged

test: adjust WedDav preview test case for Devanagari script [full-ci]#41672
phil-davis merged 1 commit into
masterfrom
test-fix-previews-feature-211

Conversation

@phil-davis

Copy link
Copy Markdown
Contributor

This acceptance test case use Devenagari script as an example of a non-Latin script. It confirms that a preview of a text file containing Devanagari script can be produced in PNG format.

The preview used in the test scenario has been made bigger (64x64). That makes the graphic resolution good enough that I can manually recognise the characters rendered in the resulting PNG image, and confirm that they are a good rendering of the text.

Note: depending on the installed environment, some Devanagari ligatures may not be rendered correctly. That also applies for other scripts. If an installation wants to accurately support rendering of a wide range of scripts, then they need to organise to have suitable additional libraries installed that will support those scripts. The purpose of this test scenario is not to ensure that all scripts work correctly. The purpose is just to ensure that some combination of non-Latin characters can be correctly processed, stored as a preview, and the binary content of the preview is correctly returned to the user that called the API.

Fixes #41480

Tests only, no changelog required.

Running full-ci so that the modified acceptance test will run in CI of this PR.

This acceptance test case use Devenagari script as an example of
a non-Latin script. It confirms that a preview of a text file
containing Devanagari script can be produced in PNG format.

The preview used in the test scenario has been made bigger (64x64).
That makes the graphic resolution good enough that I can manually
recognise the characters rendered in the resulting PNG image, and
confirm that they are a good rendering of the text.

Note: depending on the installed environment, some Devanagari
ligatures may not be rendered correctly. That also applies for
other scripts. If an installation wants to accurately support
rendering of a wide range of scripts, then they need to organise
to have suitable additional libraries installed that will support
those scripts. The purpose of this test scenario is not to ensure
that all scripts work correctly. The purpose is just to ensure
that some combination of non-Latin characters can be correctly
processed, stored as a preview, and the binary content of the
preview is correctly returned to the user that called the API.
@phil-davis phil-davis requested a review from a team as a code owner July 8, 2026 09:48
@phil-davis

Copy link
Copy Markdown
Contributor Author

https://github.com/owncloud/core/actions/runs/28933473781/job/85840164502?pr=41672

  Scenario: it should update the preview content if the file content is updated (content with UTF chars)         # /home/runner/work/core/core/tests/acceptance/features/apiWebdavPreviews/previews.feature:211
    Given user "Alice" has uploaded file "filesForUpload/lorem.txt" to "/lorem.txt"                              # FeatureContext::userHasUploadedAFileTo()
    And user "Alice" has uploaded file with content "मेरो पानी" to "/lorem.txt"                                  # FeatureContext::userHasUploadedAFileWithContentTo()
    When user "Alice" downloads the preview of "/lorem.txt" with width "64" and height "64" using the WebDAV API # FeatureContext::downloadPreviewOfFiles()
    Then the HTTP status code should be "200"                                                                    # FeatureContext::thenTheHTTPStatusCodeShouldBe()
    And the downloaded image should be "64" pixels wide and "64" pixels high                                     # FeatureContext::imageDimensionsShouldBe()
    And the downloaded preview content should match with "मेरो-पानी.png" fixtures preview content                # FeatureContext::theDownloadedPreviewContentShouldMatchWithFixturesPreviewContentFor()

Scenario passed, good.

@dj4oC dj4oC left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-enables the previously @skipped WebDAV preview acceptance scenario for non-Latin (Devanagari) content, swapping the sample text/fixture to मेरो पानी and bumping the preview to 64×64 so the rendered glyphs are verifiable.

Branch target

oC11 / master — ok.

Findings

  • Security: no findings — Gherkin text + binary fixture swap only; no production code, no injection/traversal/credential surface.
  • Stability: no findings — removing @skip re-enables the scenario in the normal pipeline (the intent of #41480); no PHP 8.3 / backward-compat impact. Independently confirmed the apiWebdavPreviews acceptance shard passed on this HEAD (job 85840164502, success) — the un-skipped scenario actually runs green, not merely claimed.
  • Performance: no findings — N/A for a test-only change.
  • Test coverage: net increase — this restores previously-disabled coverage. The ≥85% gate is N/A here since no production code is touched. No changelog required is correct (repo convention for tests-only; changelog-lint is green).
  • All 45 CI checks green.
  • Minor / non-blocking: removing the @issue-41480 @skip line leaves a double blank line before the Scenario: — cosmetic, consistent with the file's blank-line separation style; no change needed.

Verdict

Commenting — clean, low-risk, tests-only change that re-enables verified-green coverage. No blocking issues; good to merge once a human maintainer signs off.

🤖 Automated review by Claude Code (security · stability · performance · coverage)


Generated by Claude Code

dj4oC commented Jul 8, 2026

Copy link
Copy Markdown
Contributor
  • Security: no findings
  • Stability: no findings
  • Performance: no findings
  • Test coverage: N/A — tests-only PR, no production code touched; re-enables previously-skipped coverage; 85% gate N/A
  • TODOs found: none
  • Dependency touched: no
  • CI status: all green (45/45; apiWebdavPreviews shard independently confirmed passing)
  • Stale review: no

🤖 Automated review by Claude Code (security · stability · performance · coverage)


Generated by Claude Code

@phil-davis phil-davis merged commit 8523528 into master Jul 9, 2026
46 checks passed
@phil-davis phil-davis deleted the test-fix-previews-feature-211 branch July 9, 2026 06:37
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.

Devanagari short-i ligature is not renedered correctly in preview

3 participants