Comments (8)
Findings
When count($this->modified)
(on WrapperRunner
) is bigger than one, then the exception is thrown.
When count($this->modified) == 1
the test suite pass.
To reproduce
check out tripsta/paratest/issues/54-wrapper-runner-exception and run
bin/paratest -p 2 --runner WrapperRunner test/fixtures/tests/EnvironmentTest.php
Example of exception
worker count in startWorkers 2
pending count 1
modifed count 2
worker count in progressedWorkers 2
PHP Catchable fatal error: Argument 1 passed to ParaTest\Runners\PHPUnit\Worker::assign() must be an instance of ParaTest\Runners\PHPUnit\ExecutableTest, null given, called in /home/dbaltas/projects/paratest/src/ParaTest/Runners/PHPUnit/WrapperRunner.php on line 89 and defined in /home/dbaltas/projects/paratest/src/ParaTest/Runners/PHPUnit/Worker.php on line 47
Example of success
worker count in startWorkers 2
pending count 1
modifed count 1
worker count in progressedWorkers 1
modifed count 1
worker count in progressedWorkers 1
modifed count 1
worker count in progressedWorkers 1
modifed count 1
worker count in progressedWorkers 1
modifed count 1
worker count in progressedWorkers 1
modifed count 1
worker count in progressedWorkers 1
modifed count 1
worker count in progressedWorkers 1
modifed count 1
worker count in progressedWorkers 1
..
Time: 0 seconds, Memory: 3.25Mb
OK (2 tests, 6 assertions)
from paratest.
Thank you for the investigation, since it can be reproduced I'll try to fix
this issue.
from paratest.
@giorgiosironi Is the above fix OK?
Also this issue still persists in last builds of master in travis 118,121, even though it passed on 119 with the same code as 121,
1) PerformanceTest::testRunningSuitesWithLongBootstrapsIsFasterWithTheWrapperRunner
Symfony\Component\Process\Exception\RuntimeException: The process timed-out.
from paratest.
Yes, the fix is ok as this is a race condition between $this->pending and "more workers than pending tests" being available in a single shot. I'll look at master and see if I can reproduce the issue.
from paratest.
I'll download a 5.3 VM to get the same problem.
from paratest.
Reproduced on 5.3.10, with a similar test. Symfony/Process has a default timeout of 60 seconds for a process (don't know between which events it is measured), and that stops the suite.
PHP 5.3 is nototiously slower than 5.4, so that's probably why it is happening only in that environment.
from paratest.
I got a green build here:
https://travis-ci.org/giorgiosironi/paratest
and the identical commit failing on 5.3 here:
https://travis-ci.org/brianium/paratest
from paratest.
Its OK. Thumbs up!
from paratest.
Related Issues (20)
- Multiple skipped not reported HOT 4
- SQLSTATE[HY000]: General error: 11 database disk image is malformed HOT 2
- paratest_for_phpstorm deadlock issues where not present in command line runner HOT 3
- WorkerCrashedException on class not found HOT 1
- Bad progress output with option --functional HOT 5
- PHPStorm on Windows: Missing path to '/paratest_for_phpstorm' HOT 2
- Reversion from v6: Output test descriptions while tests are running with --testdox HOT 3
- PHPUnit 11 support HOT 4
- Cache for static analysis has not been configured HOT 3
- Dynamically allocate tests to available workers HOT 1
- Bug with --testdox option at v7.4.0 HOT 3
- Unit testing failing on multiple database connection HOT 1
- After upgrading our app to Laravel 10 + php 8.2, I keep getting "Test was run in child process and ended unexpectedly" with parallel testing on github HOT 4
- Performance issue on new machine HOT 2
- Wait between test HOT 4
- Issue with teamcity reporting in PhpStorm HOT 1
- PHPUnit progress shown when test has >=1000 steps
- Repeated cli options are not working as expected
- [Bug]: Skipped installation of bin bin/paratest.bat for package brianium/paratest: name conflicts with an existing file HOT 4
- Code coverage: Cache for static analysis has not been configured HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from paratest.