Skip to content

test: fix codeigniter.unknownServiceMethod errors #9532

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

paulbalandan
Copy link
Member

Description
These errors are not phpstan false reports. These are intended for testing purposes thus we can safely locally ignore them.

Checklist:

  • Securely signed commits
  • Component(s) with PHPDoc blocks, only if necessary or adds value
  • Unit testing, with >80% coverage
  • User guide updated
  • Conforms to style guide

@paulbalandan paulbalandan added the testing Pull requests that changes tests only label Apr 18, 2025
Copy link
Member

@michalsn michalsn left a comment

Choose a reason for hiding this comment

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

I'm not sure I understand the benefit of moving these from the baseline file into inline comments.

I get that the baseline is typically used for issues we plan to fix eventually - but filling the source code with a lot of phpstan suppression comments doesn't feel ideal either.

I have mixed feelings about it, but it seems like the right choice for now.

@paulbalandan
Copy link
Member Author

The way I see it:

  1. To phpstan baseline - those errors are to be fixed someday. A technical debt for us
  2. Inlining - those errors are intended primarily for testing purposes so they are not fixable

@paulbalandan paulbalandan force-pushed the unknown-service-method-name branch from bcaeeea to c0bbac4 Compare April 19, 2025 14:30
@paulbalandan paulbalandan merged commit caf9f34 into codeigniter4:develop Apr 19, 2025
47 checks passed
@paulbalandan paulbalandan deleted the unknown-service-method-name branch April 19, 2025 15:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
testing Pull requests that changes tests only
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants