Skip to content

refactor: extract legacy editor file migration - #122

Merged
erseco merged 4 commits into
test/coverage-page-controllersfrom
refactor/editor-legacy-migration-service
Sep 22, 2026
Merged

erseco merged 4 commits into
test/coverage-page-controllersfrom
refactor/editor-legacy-migration-service

Conversation

@erseco

@erseco erseco commented Sep 22, 2026

Copy link
Copy Markdown
Contributor

Summary

  • move best-effort .elp.elpx rename logic out of EditorController
  • introduce LegacyFileMigrationService
  • keep collision handling, move failures, and post-move refetch semantics unchanged
  • add exhaustive unit tests for names, parent lookup, collision suffixes, move errors, and refetch errors
  • rely on the existing lib/Service coverage scope, so the new service must keep the backend above 90%

Why

This is the fourth stacked step toward covering EditorController. The repository testing guidance recommends extracting logic from controllers into collaborator-driven services rather than building a fake Nextcloud container in unit tests.

Stack

Depends on #121#120#119.

The next/final PR will cover the remaining EditorController orchestration using this service.

Validation

  • CI: green
  • Playground preview: green
  • backend coverage: 94.37%
  • LegacyFileMigrationService: 100% lines

@github-actions

github-actions Bot commented Sep 22, 2026

Copy link
Copy Markdown
Contributor

Preview this PR in the Nextcloud Playground

Open this PR in the Nextcloud Playground

A fresh Nextcloud boots in your browser with this branch's exelearning app installed and enabled (log in as admin / admin). Two sample .elpx are seeded under exelearning-samples/ in Files — click one to open the viewer.

eXeLearning editor: v4.0.5 (overlaid at boot from the upstream release).

@codecov-commenter

codecov-commenter commented Sep 22, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.12%. Comparing base (4f08f71) to head (6422b8b).

Additional details and impacted files
@@                         Coverage Diff                          @@
##             test/coverage-page-controllers     #122      +/-   ##
====================================================================
+ Coverage                             94.93%   95.12%   +0.19%     
- Complexity                              114      124      +10     
====================================================================
  Files                                    19       20       +1     
  Lines                                   513      533      +20     
  Branches                                 54       54              
====================================================================
+ Hits                                    487      507      +20     
  Misses                                   19       19              
  Partials                                  7        7              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@erseco
erseco marked this pull request as ready for review September 22, 2026 04:18
@erseco
erseco added this pull request to stack #124 September 22, 2026 05:37
@erseco
erseco force-pushed the refactor/editor-legacy-migration-service branch from 32be43e to 6422b8b Compare September 22, 2026 05:38
@erseco
erseco merged commit c4fdf5e into main Sep 22, 2026
16 checks passed
@erseco
erseco deleted the refactor/editor-legacy-migration-service branch September 22, 2026 05:42
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.

2 participants