Skip to content
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

Intermittent unit test failure - assertCount() must be a countable or iterable #925

Open
golenkovm opened this issue Jan 29, 2025 · 0 comments

Comments

@golenkovm
Copy link

The following was thrown in one of the builds:

There was 1 error:

1) tool_dataflows\tool_dataflows_event_processor_test::test_process_event_immediate
PHPUnit\Framework\InvalidArgumentException: Argument #2 of PHPUnit\Framework\Assert::assertCount() must be a countable or iterable

/var/www/site/admin/tool/dataflows/tests/tool_dataflows_event_processor_test.php:199
/var/www/site/lib/phpunit/classes/advanced_testcase.php:80

ERRORS!
Tests: 4890, Assertions: 29196, Errors: 1, Skipped: 25.

Env details:

Moodle 4.1.15+ (Build: 20250124)
Php: 8.1.2.1.2.20, pgsql: 14.15 (Debian 14.15-1.pgdg120+1), OS: Linux 6.8.0-1021-aws x86_64
PHPUnit 9.5.28
Plugin branch MOODLE_401_STABLE
Plugin hash 64e587ae5e5554a390e824c878171acc9d2abc5d

Testing this in a local devbox didn't confirm the issue. Re-running in GoCD surprisingly self-healed the issue (the test passed). Raising this in case it will explode somewhere else.

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

No branches or pull requests

1 participant