Skip to content
This repository was archived by the owner on Apr 14, 2025. It is now read-only.

Conversation

wiese
Copy link
Contributor

@wiese wiese commented Oct 24, 2016

For the moment I only applied changes keeping original functionality, but looking forward, the token analysis also gives us a head start building a more robust way to get e.g. the data providers, maybe combined w/ 3rd party annotation parsing (doctrine/annotations).

Cheers

@wiese wiese mentioned this pull request Oct 24, 2016
Closed
if (!count($classes))
{
return $numTestsInFile;
}
Copy link
Owner

Choose a reason for hiding this comment

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

Is $classes an array? If so, change this block of code to the following:

if (!$classes) {
    return $numTestsInFile;
}

If it is not an array, keep the count and move the opening { up to the same line as the if.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Are you referring strictly to code style or am I missing something? Thx

@jwage
Copy link
Owner

jwage commented Oct 24, 2016

Can you test jwage/phpchunkit-demo against this branch?

@jwage
Copy link
Owner

jwage commented Oct 24, 2016

This will fix #9.

@jwage
Copy link
Owner

jwage commented Oct 24, 2016

👍

@wiese
Copy link
Contributor Author

wiese commented Oct 25, 2016

[wiese@localhost phpchunkit-demo]$ composer.phar info jwage/phpchunkit
name     : jwage/phpchunkit
descrip. : PHPUnit Test Runner
keywords : phpunit, tests
versions : * dev-patch-4
...
[wiese@localhost phpchunkit-demo]$ docker run -v $(pwd):/app -w "/app" --rm php ./vendor/bin/phpchunkit all
PHPUnit 5.5.7 by Sebastian Bergmann and contributors.

.....                                                               5 / 5 (100%)

Time: 71 ms, Memory: 4.00MB

OK (5 tests, 5 assertions)
Total Tests: 8
Number of Chunks Configured: 14
Number of Chunks Produced: 2
Tests Per Chunk: ~1
-----------

Running chunk #1

 1/4 [🌭]  25%
 4/4 [=] 100%
Running chunk #2

 1/4 [🌭]  25%
 4/4 [=] 100%

Time: 0.12 seconds, Memory: 4MB

OK (14 chunks, 8 tests)

Seems to work

@jwage
Copy link
Owner

jwage commented Oct 25, 2016

👍 anything else you want to take care of here or are you ready to merge?

@wiese
Copy link
Contributor Author

wiese commented Oct 25, 2016

No amendments in this matter. If you feel it's good, please do the honours.

@jwage jwage merged commit b9e5426 into jwage:master Oct 25, 2016
@wiese wiese deleted the patch-4 branch October 25, 2016 13:29
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants