Skip to content

Conversation

whataboutpereira
Copy link

Check valid field names are used in orderBy parameter of findBy and findOneBy repository methods (issue #674).

Unfortunately this won't catch a nested call like this:

    public function findAll(array $orderBy = ['name' => 'ASC']): array
    {
        return $this->findBy([], $orderBy);
    }

@whataboutpereira whataboutpereira force-pushed the check-findBy-order-by-fields branch from e27b1ee to 5df2683 Compare September 22, 2025 08:18
@staabm
Copy link
Contributor

staabm commented Oct 8, 2025

@ondrejmirtes could you rebase this branch so we can see how/whether mutation testing is doing here?

@ondrejmirtes ondrejmirtes force-pushed the check-findBy-order-by-fields branch from 5df2683 to fb46445 Compare October 8, 2025 10:50
@ondrejmirtes
Copy link
Member

Rebased

@staabm
Copy link
Contributor

staabm commented Oct 8, 2025

thanks.

test succeeded, as this PR does not contain any ->yes() or ->no() invocation, which means no mutations are generated. mutation testing jobs are green as expected.

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.

3 participants