Skip to content

chore: fix most moodle plugin ci issues#46

Merged
daniil-berg merged 3 commits intomainfrom
chore/fix-most-moodle-plugin-ci-issues
Jan 29, 2026
Merged

chore: fix most moodle plugin ci issues#46
daniil-berg merged 3 commits intomainfrom
chore/fix-most-moodle-plugin-ci-issues

Conversation

@daniil-berg
Copy link
Copy Markdown
Owner

@daniil-berg daniil-berg commented Jan 28, 2026

  • Doc blocks everywhere.
  • #[\Override] attributes on overridden methods.
  • defined('MOODLE_INTERNAL') || die(); wherever necessary.
  • Proper use of spaces/newlines.
  • final unit test classes.
  • Correct data provider function names.
  • Workarounds for local_moodlecheck false positives. Skip the Moodle PHPDoc checker entirely. (see here)
  • Explicitly disabled Squiz.WhiteSpace.ScopeClosingBrace for empty constructors.
  • Explicitly disabled moodle.PHP.ForbiddenTokens.Found for unit test metric factory eval call.
  • Reword a few things.

What I intentionally did not fix is anything in our local/metrics classes (because those will be reworked separately via #11) and the false positives for final readonly classes (addressed in this PR).

The latter is what is causing those nonsensical Expected MOODLE_INTERNAL check ... errors for classes like metric_value for example.

- Doc blocks everywhere.
- `#[\Override]` attributes on overridden methods.
- `defined('MOODLE_INTERNAL') || die();` wherever necessary.
- Proper use of spaces/newlines.
- `final` unit test classes.
- Correct data provider function names.
- Workarounds for `local_moodlecheck` false positives.
- Explicitly disabled `Squiz.WhiteSpace.ScopeClosingBrace` for empty constructors.
- Explicitly disabled `moodle.PHP.ForbiddenTokens.Found` for unit test metric factory `eval` call.
- Reword a few things.
@daniil-berg daniil-berg merged commit 9c50448 into main Jan 29, 2026
0 of 12 checks passed
@github-project-automation github-project-automation Bot moved this from Todo to Done in Monitoring Moodle Jan 29, 2026
@daniil-berg daniil-berg deleted the chore/fix-most-moodle-plugin-ci-issues branch February 27, 2026 12:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant