Skip to content

CodeCoverage driver for PCOV #661

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

Closed
wants to merge 17 commits into from
Closed

CodeCoverage driver for PCOV #661

wants to merge 17 commits into from

Conversation

krakjoe
Copy link
Contributor

@krakjoe krakjoe commented Jan 17, 2019

Driver for krakjoe/pcov

Initial testing shows this to be faster than phpdbg when configured correctly.

I'm not able to use the Filter object to configure it, so for the moment the extension is configured by ini.

@codecov
Copy link

codecov bot commented Jan 17, 2019

Codecov Report

Merging #661 into master will decrease coverage by 0.06%.
The diff coverage is 0%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master     #661      +/-   ##
============================================
- Coverage     85.16%   85.09%   -0.07%     
- Complexity      805      806       +1     
============================================
  Files            32       32              
  Lines          2534     2536       +2     
============================================
  Hits           2158     2158              
- Misses          376      378       +2
Impacted Files Coverage Δ Complexity Δ
src/CodeCoverage.php 73.46% <0%> (-0.38%) 181 <0> (+1)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update afe4b8a...6b4fd44. Read the comment docs.

@sebastianbergmann
Copy link
Owner

Thank you for this pull request, Joe.

I am reluctant to merge this, though, until there is proof that when used with PCOV, PHPUnit generates the same report for real-world projects (the Symfony test suite is a good candidate).

Please understand that I am not motivated to invest the time need to perform the above mentioned comparison as Xdebug is good enough for me.

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 18, 2019

Hi Sebastian ...

I'm not expecting a quick merge, the extension has existed for days only, a day when I opened the PR ...

I don't mind putting in the leg work at all: I'm doing testing and benchmarking now and will update when I'm happy with the results, and of course share them ...

Hopefully this being open will encourage others to test.

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 20, 2019

Morning Sebastian ...

So I have done a lot of testing with all of xdebug, phpdbg, and pcov. I've written in the readme the rationale for why things work the way they do for all implementations, and summarised the differences in a way that should explain why you see the real world results from phpdbg that you do.

I can't run the symfony test suite with xdebug it crashes at ~30% percent with a fatal error, which I'd be happy to dig up if you'd like to see it , I'm sure it's something in my configuration; I'm not familiar with symfony. I can run it with pcov but we have nothing to compare it too, so I hope you don't mind if we use the laravel-framework repo which I can run in all three. I'd be happy to test another suggested repo also.

I know that you're mostly interested in the results between xdebug and anything else, so that's the comparison I've made.

Here's a gist with a log from xdebug, and pcov, and the diff for easy reading ...

https://gist.github.com/krakjoe/581ef348c0028ba3480781ec6a4fe27f

I'd be happy to upload the html reports for both somewhere also ...

The summarized numbers are very close, as are the numbers in detail, the main differences are the lines counted (which most of the time makes no difference to the actual coverage), and the odd time that xdebug correctly detects that an implicit return path was not travelled and phpdbg/pcov will ignore it.

The other main difference is waiting time :)

Thoughts ?

Edit: ran comparison on phpstan, uploaded logs and phpstan.diff, same story but more data is nice and this is a more complicated test suite ...

@sebastianbergmann
Copy link
Owner

Can you add the PCOV driver to the test suite (and CI configuration)?

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 22, 2019

Sure thing ... I've had a look around, it looks like enough to add it to the CI config and then phpunit will run it when it has the correct environment package and can detect the driver, does that sound right to you ?

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 22, 2019

I've added and ran a test build with just pcov on travis and it failed with no code coverage driver available so it's just waiting for environment change, I think.

@sebastianbergmann
Copy link
Owner

Could you not just modify composer.json in your branch of this repository to pull in your branch of environment? Then Travis should use that for the build(s) of this pull request.

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 23, 2019

I think I got it ...

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 23, 2019

I don't know how, I don't think it's possible with the circular nature of the require-dev dependency on phpunit which requires php-code-coverage which can't be satisfied ...

https://travis-ci.org/krakjoe/php-code-coverage/jobs/483255265

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 23, 2019

I got nothing, it's certainly not just a case of editing a composer.json, I've had to fork phpunit and create a branch in that, and I still can't satisfy requirements ... and even if I could, most of the builds would fail because of php version requirements ... so I'm not sure what we would get out of that ...

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 23, 2019

@sebastianbergmann we can't do this composer magic, we think we have discovered a bug in composer, it is seems as if it is forgetting the aliases we are setting ...

I think we want Jordi's attention /cc @Saldaek

composer.json Outdated
@@ -32,12 +46,12 @@
"phpunit/php-token-stream": "^3.0.1",
"phpunit/php-text-template": "^1.2.1",
"sebastian/code-unit-reverse-lookup": "^1.0.1",
"sebastian/environment": "^4.0",
"sebastian/environment": "dev-pcov",
Copy link

Choose a reason for hiding this comment

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

You can require dev-pcov as 4.0.99 to alias that package here and same below for phpunit I suppose.

Copy link

Choose a reason for hiding this comment

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

Ah I see you just removed the aliases. I don't know why they didn't work.

.travis.yml Outdated

before_install:
- composer self-update
- composer clear-cache
- composer config github-oauth.github.com ${GH_TOKEN}
Copy link

Choose a reason for hiding this comment

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

I don't think this helps unless @sebastianbergmann defines the env var..

}
}
},
"minimum-stability": "dev"
Copy link

Choose a reason for hiding this comment

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

Remove this as it'll only hurt resolution as it pulls everything in dev. It's not necessary if you explicitly require dev-... versions above.

composer.json Outdated
@@ -55,7 +69,8 @@
},
"extra": {
"branch-alias": {
"dev-master": "6.1-dev"
"dev-pcov": "6.1.4"
Copy link

Choose a reason for hiding this comment

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

This in theory shouldn't be needed but probably doesn't hurt

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 23, 2019 via email

@Seldaek
Copy link

Seldaek commented Jan 23, 2019

Sorry but I have no idea what you are trying to do. There's been 10 hacky commits and things seem to get worse and worse.

If https://travis-ci.org/krakjoe/php-code-coverage/jobs/483255265 was the initial problem, I'd suggest reverting composer.json to that state, and then only adding COMPOSER_ROOT_VERSION=6.1.99 before the composer update command in travis config (or just export that env var somewhere before), which should let it assume a correct php-code-coverage version. I believe that was the only issue you had.

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 23, 2019 via email

@Seldaek
Copy link

Seldaek commented Jan 23, 2019

Yeah so only the sebastianbergmann/environment custom vcs repository is needed then (with an alias in the require), and the COMPOSER_ROOT_VERSION as I said in my previous comment. That should work AFAIK.

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 23, 2019 via email

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 23, 2019

I noticed :) will exported after clear-cache be okay ? ... that's what's running now ...

Edit ... nope ...

  Problem 1
    - phpunit/phpunit 7.4.4 requires sebastian/environment ^3.1 || ^4.0 -> satisfiable by sebastian/environment[4.0.x-dev].
    - phpunit/phpunit 7.4.5 requires sebastian/environment ^4.0 -> satisfiable by sebastian/environment[4.0.x-dev].
    - phpunit/phpunit 7.5.0 requires sebastian/environment ^4.0 -> satisfiable by sebastian/environment[4.0.x-dev].
    - phpunit/phpunit 7.5.1 requires sebastian/environment ^4.0 -> satisfiable by sebastian/environment[4.0.x-dev].
    - phpunit/phpunit 7.5.2 requires sebastian/environment ^4.0 -> satisfiable by sebastian/environment[4.0.x-dev].
    - phpunit/phpunit 7.5.x-dev requires sebastian/environment ^4.0 -> satisfiable by sebastian/environment[4.0.x-dev].
    - Can only install one of: sebastian/environment[4.0.x-dev, dev-pcov].
    - Can only install one of: sebastian/environment[dev-pcov, 4.0.x-dev].
    - Installation request for sebastian/environment dev-pcov -> satisfiable by sebastian/environment[dev-pcov].
    - Installation request for phpunit/phpunit ^7.4.4 -> satisfiable by phpunit/phpunit[7.4.4, 7.4.5, 7.5.0, 7.5.1, 7.5.2, 7.5.x-dev].

export before anything else ?

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 23, 2019

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 23, 2019

@Seldaek
Copy link

Seldaek commented Jan 23, 2019

👍 cool

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 24, 2019

@sebastianbergmann this is a diff from pcov 0.9.1-dev and xdebug on laravel-framework (this is as yet untagged/unreleased, soon) ...

--- pcov.log	2019-01-24 13:42:12.843233502 +0100
+++ xdebug.log	2019-01-24 13:28:27.525361057 +0100
@@ -1,6 +1,6 @@
 PHPUnit 7.5.2 by Sebastian Bergmann and contributors.
 
-Runtime:       PHP 7.3.3-dev
+Runtime:       PHP 7.3.3-dev with Xdebug 2.7.0beta2-dev
 Configuration: /opt/src/laravel-framework/phpunit.xml.dist
 
 .............................................................   61 / 3772 (  1%)
@@ -66,7 +66,7 @@
 ............................................................. 3721 / 3772 ( 98%)
 ...................................................           3772 / 3772 (100%)
 
-Time: 20.73 seconds, Memory: 240.00MB
+Time: 1.71 minutes, Memory: 186.00MB
 
 There was 1 error:
 
@@ -265,17 +265,17 @@
 
 
 Code Coverage Report:          
-  2019-01-24 12:41:49          
+  2019-01-24 12:26:29          
                                
  Summary:                      
-  Classes: 27.50% (184/669)    
-  Methods: 65.70% (4150/6317)  
-  Lines:   71.88% (14896/20722)
+  Classes: 27.35% (183/669)    
+  Methods: 66.01% (4170/6317)  
+  Lines:   72.53% (14989/20666)
 
 \Illuminate\Auth::Authenticatable
   Methods: 100.00% ( 6/ 6)   Lines: 100.00% ( 10/ 10)
 \Illuminate\Auth::CreatesUserProviders
-  Methods:  20.00% ( 1/ 5)   Lines:  44.44% (  8/ 18)
+  Methods:  20.00% ( 1/ 5)   Lines:  47.37% (  9/ 19)
 \Illuminate\Auth::GuardHelpers
   Methods:  75.00% ( 6/ 8)   Lines:  78.57% ( 11/ 14)
 \Illuminate\Auth::Illuminate\Auth\AuthManager
@@ -285,9 +285,9 @@
 \Illuminate\Auth::Illuminate\Auth\AuthenticationException
   Methods:  66.67% ( 2/ 3)   Lines:  83.33% (  5/  6)
 \Illuminate\Auth::Illuminate\Auth\DatabaseUserProvider
-  Methods:  71.43% ( 5/ 7)   Lines:  83.87% ( 26/ 31)
+  Methods:  71.43% ( 5/ 7)   Lines:  84.38% ( 27/ 32)
 \Illuminate\Auth::Illuminate\Auth\EloquentUserProvider
-  Methods:  54.55% ( 6/11)   Lines:  82.50% ( 33/ 40)
+  Methods:  54.55% ( 6/11)   Lines:  82.93% ( 34/ 41)
 \Illuminate\Auth::Illuminate\Auth\GenericUser
   Methods:  54.55% ( 6/11)   Lines:  50.00% (  8/ 16)
 \Illuminate\Auth::Illuminate\Auth\Recaller
@@ -301,7 +301,7 @@
 \Illuminate\Auth\Access::HandlesAuthorization
   Methods: 100.00% ( 2/ 2)   Lines: 100.00% (  2/  2)
 \Illuminate\Auth\Access::Illuminate\Auth\Access\Gate
-  Methods:  78.12% (25/32)   Lines:  93.15% (136/146)
+  Methods:  78.12% (25/32)   Lines:  93.24% (138/148)
 \Illuminate\Auth\Access::Illuminate\Auth\Access\Response
   Methods: 100.00% ( 3/ 3)   Lines: 100.00% (  4/  4)
 \Illuminate\Auth\Events::Illuminate\Auth\Events\Attempting
@@ -337,7 +337,7 @@
 \Illuminate\Broadcasting::Illuminate\Broadcasting\PrivateChannel
   Methods: 100.00% ( 1/ 1)   Lines: 100.00% (  2/  2)
 \Illuminate\Broadcasting\Broadcasters::Illuminate\Broadcasting\Broadcasters\Broadcaster
-  Methods:  69.23% ( 9/13)   Lines:  72.55% ( 37/ 51)
+  Methods:  69.23% ( 9/13)   Lines:  71.70% ( 38/ 53)
 \Illuminate\Bus::Illuminate\Bus\BusServiceProvider
   Methods: 100.00% ( 2/ 2)   Lines: 100.00% (  9/  9)
 \Illuminate\Bus::Illuminate\Bus\Dispatcher
@@ -433,7 +433,7 @@
 \Illuminate\Console\Scheduling::Illuminate\Console\Scheduling\ScheduleFinishCommand
   Methods:  50.00% ( 1/ 2)   Lines:  50.00% (  3/  6)
 \Illuminate\Console\Scheduling::Illuminate\Console\Scheduling\ScheduleRunCommand
-  Methods:  25.00% ( 1/ 4)   Lines:  19.05% (  4/ 21)
+  Methods:  25.00% ( 1/ 4)   Lines:  18.18% (  4/ 22)
 \Illuminate\Console\Scheduling::ManagesFrequencies
   Methods:  76.47% (26/34)   Lines:  74.60% ( 47/ 63)
 \Illuminate\Container::Illuminate\Container\BoundMethod
@@ -451,13 +451,13 @@
 \Illuminate\Cookie\Middleware::Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse
   Methods:  50.00% ( 1/ 2)   Lines:  66.67% (  4/  6)
 \Illuminate\Cookie\Middleware::Illuminate\Cookie\Middleware\EncryptCookies
-  Methods:  60.00% ( 6/10)   Lines:  53.33% ( 16/ 30)
+  Methods:  60.00% ( 6/10)   Lines:  53.12% ( 17/ 32)
 \Illuminate\Database::DetectsDeadlocks
   Methods: 100.00% ( 1/ 1)   Lines: 100.00% (  3/  3)
 \Illuminate\Database::DetectsLostConnections
   Methods: 100.00% ( 1/ 1)   Lines: 100.00% (  3/  3)
 \Illuminate\Database::Illuminate\Database\Connection
-  Methods:  74.32% (55/74)   Lines:  85.39% (187/219)
+  Methods:  74.32% (55/74)   Lines:  85.45% (188/220)
 \Illuminate\Database::Illuminate\Database\DatabaseManager
   Methods:  27.78% ( 5/18)   Lines:  50.00% ( 30/ 60)
 \Illuminate\Database::Illuminate\Database\DatabaseServiceProvider
@@ -471,17 +471,17 @@
 \Illuminate\Database::Illuminate\Database\QueryException
   Methods:  50.00% ( 2/ 4)   Lines:  81.82% (  9/ 11)
 \Illuminate\Database::Illuminate\Database\SQLiteConnection
-  Methods: 100.00% ( 7/ 7)   Lines: 100.00% ( 16/ 16)
+  Methods:  85.71% ( 6/ 7)   Lines:  93.75% ( 15/ 16)
 \Illuminate\Database::Illuminate\Database\Seeder
   Methods:  50.00% ( 3/ 6)   Lines:  83.33% ( 20/ 24)
 \Illuminate\Database\Capsule::Illuminate\Database\Capsule\Manager
   Methods:  71.43% (10/14)   Lines:  80.65% ( 25/ 31)
 \Illuminate\Database\Concerns::BuildsQueries
-  Methods:  87.50% ( 7/ 8)   Lines:  87.10% ( 27/ 31)
+  Methods:  87.50% ( 7/ 8)   Lines:  87.50% ( 28/ 32)
 \Illuminate\Database\Concerns::ManagesTransactions
   Methods:  63.64% ( 7/11)   Lines:  83.08% ( 54/ 65)
 \Illuminate\Database\Connectors::Illuminate\Database\Connectors\ConnectionFactory
-  Methods:  75.00% (12/16)   Lines:  87.10% ( 54/ 62)
+  Methods:  75.00% (12/16)   Lines:  85.71% ( 54/ 63)
 \Illuminate\Database\Connectors::Illuminate\Database\Connectors\Connector
   Methods:  57.14% ( 4/ 7)   Lines:  84.21% ( 16/ 19)
 \Illuminate\Database\Connectors::Illuminate\Database\Connectors\MySqlConnector
@@ -519,13 +519,13 @@
 \Illuminate\Database\Console\Seeds::Illuminate\Database\Console\Seeds\SeederMakeCommand
   Methods:  20.00% ( 1/ 5)   Lines:  33.33% (  3/  9)
 \Illuminate\Database\Eloquent::Illuminate\Database\Eloquent\Builder
-  Methods:  94.29% (66/70)   Lines:  95.77% (272/284)
+  Methods:  94.29% (66/70)   Lines:  95.80% (274/286)
 \Illuminate\Database\Eloquent::Illuminate\Database\Eloquent\Collection
   Methods:  87.10% (27/31)   Lines:  97.33% (146/150)
 \Illuminate\Database\Eloquent::Illuminate\Database\Eloquent\Factory
   Methods:  38.10% ( 8/21)   Lines:  42.86% ( 15/ 35)
 \Illuminate\Database\Eloquent::Illuminate\Database\Eloquent\FactoryBuilder
-  Methods:  70.00% (14/20)   Lines:  86.17% ( 81/ 94)
+  Methods:  70.00% (14/20)   Lines:  86.46% ( 83/ 96)
 \Illuminate\Database\Eloquent::Illuminate\Database\Eloquent\JsonEncodingException
   Methods:  50.00% ( 1/ 2)   Lines:  66.67% (  2/  3)
 \Illuminate\Database\Eloquent::Illuminate\Database\Eloquent\Model
@@ -541,13 +541,13 @@
 \Illuminate\Database\Eloquent\Concerns::GuardsAttributes
   Methods: 100.00% (12/12)   Lines: 100.00% ( 29/ 29)
 \Illuminate\Database\Eloquent\Concerns::HasAttributes
-  Methods:  95.45% (63/66)   Lines:  97.71% (256/262)
+  Methods:  95.45% (63/66)   Lines:  97.74% (259/265)
 \Illuminate\Database\Eloquent\Concerns::HasEvents
   Methods:  52.17% (12/23)   Lines:  72.97% ( 54/ 74)
 \Illuminate\Database\Eloquent\Concerns::HasGlobalScopes
   Methods:  25.00% ( 1/ 4)   Lines:  53.85% (  7/ 13)
 \Illuminate\Database\Eloquent\Concerns::HasRelationships
-  Methods:  92.31% (36/39)   Lines:  97.56% (120/123)
+  Methods:  92.31% (36/39)   Lines:  97.58% (121/124)
 \Illuminate\Database\Eloquent\Concerns::HasTimestamps
   Methods:  88.89% ( 8/ 9)   Lines:  95.00% ( 19/ 20)
 \Illuminate\Database\Eloquent\Concerns::HidesAttributes
@@ -597,9 +597,9 @@
 \Illuminate\Database\Migrations::Illuminate\Database\Migrations\MigrationCreator
   Methods:  91.67% (11/12)   Lines:  96.67% ( 29/ 30)
 \Illuminate\Database\Migrations::Illuminate\Database\Migrations\Migrator
-  Methods:  48.28% (14/29)   Lines:  78.05% ( 96/123)
+  Methods:  48.28% (14/29)   Lines:  78.23% ( 97/124)
 \Illuminate\Database\Query::Illuminate\Database\Query\Builder
-  Methods:  82.91% (131/158)   Lines:  92.50% (493/533)
+  Methods:  82.91% (131/158)   Lines:  92.51% (494/534)
 \Illuminate\Database\Query::Illuminate\Database\Query\Expression
   Methods: 100.00% ( 3/ 3)   Lines: 100.00% (  4/  4)
 \Illuminate\Database\Query::Illuminate\Database\Query\JoinClause
@@ -625,13 +625,13 @@
 \Illuminate\Database\Query\Processors::Illuminate\Database\Query\Processors\SQLiteProcessor
   Methods: 100.00% ( 1/ 1)   Lines: 100.00% (  2/  2)
 \Illuminate\Database\Schema::Illuminate\Database\Schema\Blueprint
-  Methods:  88.12% (89/101)   Lines:  88.46% (161/182)
+  Methods:  88.12% (89/101)   Lines:  88.52% (162/183)
 \Illuminate\Database\Schema::Illuminate\Database\Schema\Builder
   Methods:  61.90% (13/21)   Lines:  74.55% ( 41/ 55)
 \Illuminate\Database\Schema::Illuminate\Database\Schema\SQLiteBuilder
   Methods:  33.33% ( 1/ 3)   Lines:  78.57% ( 11/ 14)
 \Illuminate\Database\Schema\Grammars::Illuminate\Database\Schema\Grammars\ChangeColumn
-  Methods:  44.44% ( 4/ 9)   Lines:  64.41% ( 38/ 59)
+  Methods:  44.44% ( 4/ 9)   Lines:  63.49% ( 40/ 63)
 \Illuminate\Database\Schema\Grammars::Illuminate\Database\Schema\Grammars\Grammar
   Methods:  86.67% (13/15)   Lines:  95.65% ( 44/ 46)
 \Illuminate\Database\Schema\Grammars::Illuminate\Database\Schema\Grammars\MySqlGrammar
@@ -651,7 +651,7 @@
 \Illuminate\Events::Illuminate\Events\CallQueuedListener
   Methods:  14.29% ( 1/ 7)   Lines:  15.38% (  4/ 26)
 \Illuminate\Events::Illuminate\Events\Dispatcher
-  Methods:  81.25% (26/32)   Lines:  90.60% (106/117)
+  Methods:  81.25% (26/32)   Lines:  89.92% (107/119)
 \Illuminate\Events::Illuminate\Events\EventServiceProvider
   Methods: 100.00% ( 1/ 1)   Lines: 100.00% (  4/  4)
 \Illuminate\Filesystem::Illuminate\Filesystem\Filesystem
@@ -739,7 +739,7 @@
 \Illuminate\Foundation\Http::Illuminate\Foundation\Http\FormRequest
   Methods:  76.92% (10/13)   Lines:  86.11% ( 31/ 36)
 \Illuminate\Foundation\Http::Illuminate\Foundation\Http\Kernel
-  Methods:  52.94% ( 9/17)   Lines:  78.46% ( 51/ 65)
+  Methods:  52.94% ( 9/17)   Lines:  77.27% ( 51/ 66)
 \Illuminate\Foundation\Http\Events::Illuminate\Foundation\Http\Events\RequestHandled
   Methods: 100.00% ( 1/ 1)   Lines: 100.00% (  3/  3)
 \Illuminate\Foundation\Http\Exceptions::Illuminate\Foundation\Http\Exceptions\MaintenanceModeException
@@ -753,7 +753,7 @@
 \Illuminate\Foundation\Http\Middleware::Illuminate\Foundation\Http\Middleware\TrimStrings
   Methods:   0.00% ( 0/ 1)   Lines:  66.67% (  2/  3)
 \Illuminate\Foundation\Http\Middleware::Illuminate\Foundation\Http\Middleware\ValidatePostSize
-  Methods:   0.00% ( 0/ 2)   Lines:  60.00% (  9/ 15)
+  Methods:   0.00% ( 0/ 2)   Lines:  62.50% ( 10/ 16)
 \Illuminate\Foundation\Http\Middleware::Illuminate\Foundation\Http\Middleware\VerifyCsrfToken
   Methods:  20.00% ( 2/10)   Lines:  25.71% (  9/ 35)
 \Illuminate\Foundation\Providers::Illuminate\Foundation\Providers\ArtisanServiceProvider
@@ -767,7 +767,7 @@
 \Illuminate\Foundation\Testing::Illuminate\Foundation\Testing\PendingCommand
   Methods:  33.33% ( 3/ 9)   Lines:  56.60% ( 30/ 53)
 \Illuminate\Foundation\Testing::Illuminate\Foundation\Testing\TestResponse
-  Methods:  43.64% (24/55)   Lines:  52.96% (152/287)
+  Methods:  43.64% (24/55)   Lines:  52.76% (153/290)
 \Illuminate\Foundation\Testing\Concerns::InteractsWithAuthentication
   Methods:  88.89% ( 8/ 9)   Lines:  96.55% ( 28/ 29)
 \Illuminate\Foundation\Testing\Concerns::InteractsWithConsole
@@ -783,7 +783,7 @@
 \Illuminate\Foundation\Testing\Constraints::Illuminate\Foundation\Testing\Constraints\HasInDatabase
   Methods: 100.00% ( 5/ 5)   Lines: 100.00% ( 15/ 15)
 \Illuminate\Foundation\Testing\Constraints::Illuminate\Foundation\Testing\Constraints\SeeInOrder
-  Methods:  75.00% ( 3/ 4)   Lines:  93.75% ( 15/ 16)
+  Methods:  50.00% ( 2/ 4)   Lines:  88.24% ( 15/ 17)
 \Illuminate\Foundation\Testing\Constraints::Illuminate\Foundation\Testing\Constraints\SoftDeletedInDatabase
   Methods:  80.00% ( 4/ 5)   Lines:  75.00% ( 12/ 16)
 \Illuminate\Hashing::Illuminate\Hashing\AbstractHasher
@@ -845,7 +845,7 @@
 \Illuminate\Http\Testing::Illuminate\Http\Testing\File
   Methods:  42.86% ( 3/ 7)   Lines:  61.54% (  8/ 13)
 \Illuminate\Http\Testing::Illuminate\Http\Testing\FileFactory
-  Methods:  33.33% ( 1/ 3)   Lines:  76.92% ( 10/ 13)
+  Methods:  33.33% ( 1/ 3)   Lines:  80.00% ( 12/ 15)
 \Illuminate\Http\Testing::Illuminate\Http\Testing\MimeType
   Methods: 100.00% ( 4/ 4)   Lines: 100.00% (  5/  5)
 \Illuminate\Log::Illuminate\Log\LogManager
@@ -895,13 +895,13 @@
 \Illuminate\Notifications::Illuminate\Notifications\Notification
   Methods:  50.00% ( 1/ 2)   Lines:  66.67% (  2/  3)
 \Illuminate\Notifications::Illuminate\Notifications\NotificationSender
-  Methods:  87.50% ( 7/ 8)   Lines:  98.04% ( 50/ 51)
+  Methods:  75.00% ( 6/ 8)   Lines:  96.15% ( 50/ 52)
 \Illuminate\Notifications::Illuminate\Notifications\NotificationServiceProvider
   Methods: 100.00% ( 2/ 2)   Lines: 100.00% ( 13/ 13)
 \Illuminate\Notifications::Illuminate\Notifications\SendQueuedNotifications
   Methods:  40.00% ( 2/ 5)   Lines:  53.33% (  8/ 15)
 \Illuminate\Notifications::RoutesNotifications
-  Methods:  66.67% ( 2/ 3)   Lines:  84.62% ( 11/ 13)
+  Methods:  66.67% ( 2/ 3)   Lines:  85.71% ( 12/ 14)
 \Illuminate\Notifications\Channels::Illuminate\Notifications\Channels\BroadcastChannel
   Methods:  66.67% ( 2/ 3)   Lines:  92.86% ( 13/ 14)
 \Illuminate\Notifications\Channels::Illuminate\Notifications\Channels\DatabaseChannel
@@ -967,7 +967,7 @@
 \Illuminate\Queue::Illuminate\Queue\SyncQueue
   Methods:  50.00% ( 5/10)   Lines:  76.92% ( 20/ 26)
 \Illuminate\Queue::Illuminate\Queue\Worker
-  Methods:  40.00% (12/30)   Lines:  66.43% ( 95/143)
+  Methods:  40.00% (12/30)   Lines:  67.13% ( 96/143)
 \Illuminate\Queue::Illuminate\Queue\WorkerOptions
   Methods: 100.00% ( 1/ 1)   Lines: 100.00% (  8/  8)
 \Illuminate\Queue::InteractsWithQueue
@@ -975,7 +975,7 @@
 \Illuminate\Queue::SerializesAndRestoresModelIdentifiers
   Methods:  60.00% ( 3/ 5)   Lines:  92.59% ( 25/ 27)
 \Illuminate\Queue::SerializesModels
-  Methods: 100.00% ( 3/ 3)   Lines: 100.00% ( 13/ 13)
+  Methods:  66.67% ( 2/ 3)   Lines:  92.86% ( 13/ 14)
 \Illuminate\Queue\Connectors::Illuminate\Queue\Connectors\SyncConnector
   Methods: 100.00% ( 1/ 1)   Lines: 100.00% (  1/  1)
 \Illuminate\Queue\Console::Illuminate\Queue\Console\FailedTableCommand
@@ -985,7 +985,7 @@
 \Illuminate\Queue\Console::Illuminate\Queue\Console\TableCommand
   Methods:  25.00% ( 1/ 4)   Lines:  22.22% (  4/ 18)
 \Illuminate\Queue\Console::Illuminate\Queue\Console\WorkCommand
-  Methods:  10.00% ( 1/10)   Lines:   6.25% (  3/ 48)
+  Methods:  10.00% ( 1/10)   Lines:   6.12% (  3/ 49)
 \Illuminate\Queue\Events::Illuminate\Queue\Events\JobExceptionOccurred
   Methods: 100.00% ( 1/ 1)   Lines: 100.00% (  4/  4)
 \Illuminate\Queue\Events::Illuminate\Queue\Events\JobFailed
@@ -1031,7 +1031,7 @@
 \Illuminate\Routing::Illuminate\Routing\ControllerMiddlewareOptions
   Methods:  66.67% ( 2/ 3)   Lines:  66.67% (  4/  6)
 \Illuminate\Routing::Illuminate\Routing\ImplicitRouteBinding
-  Methods: 100.00% ( 2/ 2)   Lines: 100.00% ( 15/ 15)
+  Methods: 100.00% ( 2/ 2)   Lines: 100.00% ( 17/ 17)
 \Illuminate\Routing::Illuminate\Routing\MiddlewareNameResolver
   Methods: 100.00% ( 2/ 2)   Lines: 100.00% ( 20/ 20)
 \Illuminate\Routing::Illuminate\Routing\PendingResourceRegistration
@@ -1045,9 +1045,9 @@
 \Illuminate\Routing::Illuminate\Routing\ResourceRegistrar
   Methods:  90.48% (19/21)   Lines:  97.62% ( 82/ 84)
 \Illuminate\Routing::Illuminate\Routing\ResponseFactory
-  Methods:  25.00% ( 4/16)   Lines:  24.00% (  6/ 25)
+  Methods:  25.00% ( 4/16)   Lines:  23.08% (  6/ 26)
 \Illuminate\Routing::Illuminate\Routing\Route
-  Methods:  77.59% (45/58)   Lines:  85.71% (132/154)
+  Methods:  75.86% (44/58)   Lines:  85.16% (132/155)
 \Illuminate\Routing::Illuminate\Routing\RouteAction
   Methods: 100.00% ( 4/ 4)   Lines: 100.00% ( 18/ 18)
 \Illuminate\Routing::Illuminate\Routing\RouteBinding
@@ -1071,7 +1071,7 @@
 \Illuminate\Routing::Illuminate\Routing\RoutingServiceProvider
   Methods:  66.67% ( 6/ 9)   Lines:  91.30% ( 42/ 46)
 \Illuminate\Routing::Illuminate\Routing\SortedMiddleware
-  Methods: 100.00% ( 3/ 3)   Lines: 100.00% ( 19/ 19)
+  Methods: 100.00% ( 3/ 3)   Lines: 100.00% ( 20/ 20)
 \Illuminate\Routing::Illuminate\Routing\UrlGenerator
   Methods:  71.79% (28/39)   Lines:  88.37% (114/129)
 \Illuminate\Routing::Illuminate\Routing\ViewController
@@ -1097,9 +1097,9 @@
 \Illuminate\Routing\Middleware::Illuminate\Routing\Middleware\SubstituteBindings
   Methods: 100.00% ( 2/ 2)   Lines: 100.00% (  5/  5)
 \Illuminate\Routing\Middleware::Illuminate\Routing\Middleware\ThrottleRequests
-  Methods:  77.78% ( 7/ 9)   Lines:  89.74% ( 35/ 39)
+  Methods:  77.78% ( 7/ 9)   Lines:  90.00% ( 36/ 40)
 \Illuminate\Routing\Middleware::Illuminate\Routing\Middleware\ThrottleRequestsWithRedis
-  Methods: 100.00% ( 5/ 5)   Lines: 100.00% ( 18/ 18)
+  Methods: 100.00% ( 5/ 5)   Lines: 100.00% ( 19/ 19)
 \Illuminate\Routing\Middleware::Illuminate\Routing\Middleware\ValidateSignature
   Methods: 100.00% ( 1/ 1)   Lines: 100.00% (  3/  3)
 \Illuminate\Session::Illuminate\Session\CookieSessionHandler
@@ -1119,9 +1119,9 @@
 \Illuminate\Support::Illuminate\Support\AggregateServiceProvider
   Methods: 100.00% ( 2/ 2)   Lines: 100.00% (  9/  9)
 \Illuminate\Support::Illuminate\Support\Arr
-  Methods: 100.00% (28/28)   Lines: 100.00% (164/164)
+  Methods: 100.00% (28/28)   Lines: 100.00% (167/167)
 \Illuminate\Support::Illuminate\Support\Collection
-  Methods:  96.83% (122/126)   Lines:  97.76% (392/401)
+  Methods:  96.83% (122/126)   Lines:  97.77% (394/403)
 \Illuminate\Support::Illuminate\Support\Composer
   Methods:  50.00% ( 3/ 6)   Lines:  66.67% ( 10/ 15)
 \Illuminate\Support::Illuminate\Support\Fluent
@@ -1141,7 +1141,7 @@
 \Illuminate\Support::Illuminate\Support\Optional
   Methods:  87.50% ( 7/ 8)   Lines:  86.96% ( 20/ 23)
 \Illuminate\Support::Illuminate\Support\Pluralizer
-  Methods:  75.00% ( 3/ 4)   Lines:  90.91% ( 10/ 11)
+  Methods:  75.00% ( 3/ 4)   Lines:  91.67% ( 11/ 12)
 \Illuminate\Support::Illuminate\Support\ProcessUtils
   Methods:   0.00% ( 0/ 2)   Lines:  10.53% (  2/ 19)
 \Illuminate\Support::Illuminate\Support\ServiceProvider
@@ -1181,7 +1181,7 @@
 \Illuminate\Support\Testing\Fakes::Illuminate\Support\Testing\Fakes\MailFake
   Methods:  61.90% (13/21)   Lines:  80.88% ( 55/ 68)
 \Illuminate\Support\Testing\Fakes::Illuminate\Support\Testing\Fakes\NotificationFake
-  Methods:  58.33% ( 7/12)   Lines:  76.27% ( 45/ 59)
+  Methods:  58.33% ( 7/12)   Lines:  76.67% ( 46/ 60)
 \Illuminate\Support\Testing\Fakes::Illuminate\Support\Testing\Fakes\PendingMailFake
   Methods: 100.00% ( 4/ 4)   Lines: 100.00% (  6/  6)
 \Illuminate\Support\Testing\Fakes::Illuminate\Support\Testing\Fakes\QueueFake
@@ -1199,11 +1199,11 @@
 \Illuminate\Translation::Illuminate\Translation\FileLoader
   Methods:  77.78% ( 7/ 9)   Lines:  93.75% ( 30/ 32)
 \Illuminate\Translation::Illuminate\Translation\MessageSelector
-  Methods:  80.00% ( 4/ 5)   Lines:  27.16% ( 88/324)
+  Methods:  80.00% ( 4/ 5)   Lines:  27.38% ( 89/325)
 \Illuminate\Translation::Illuminate\Translation\TranslationServiceProvider
   Methods: 100.00% ( 3/ 3)   Lines: 100.00% ( 12/ 12)
 \Illuminate\Translation::Illuminate\Translation\Translator
-  Methods:  78.57% (22/28)   Lines:  90.36% ( 75/ 83)
+  Methods:  78.57% (22/28)   Lines:  90.48% ( 76/ 84)
 \Illuminate\Validation::Illuminate\Validation\ClosureValidationRule
   Methods: 100.00% ( 3/ 3)   Lines: 100.00% (  8/  8)
 \Illuminate\Validation::Illuminate\Validation\DatabasePresenceVerifier
@@ -1217,11 +1217,11 @@
 \Illuminate\Validation::Illuminate\Validation\ValidationException
   Methods:  42.86% ( 3/ 7)   Lines:  52.94% (  9/ 17)
 \Illuminate\Validation::Illuminate\Validation\ValidationRuleParser
-  Methods:  84.62% (11/13)   Lines:  93.85% ( 61/ 65)
+  Methods:  84.62% (11/13)   Lines:  93.94% ( 62/ 66)
 \Illuminate\Validation::Illuminate\Validation\ValidationServiceProvider
   Methods:  50.00% ( 2/ 4)   Lines:  61.54% (  8/ 13)
 \Illuminate\Validation::Illuminate\Validation\Validator
-  Methods:  86.89% (53/61)   Lines:  95.11% (214/225)
+  Methods:  86.89% (53/61)   Lines:  95.13% (215/226)
 \Illuminate\Validation::ValidatesWhenResolvedTrait
   Methods:  33.33% ( 2/ 6)   Lines:  57.14% (  8/ 14)
 \Illuminate\Validation\Concerns::FormatsMessages
@@ -1229,7 +1229,7 @@
 \Illuminate\Validation\Concerns::ReplacesAttributes
   Methods:  96.77% (30/31)   Lines:  98.18% ( 54/ 55)
 \Illuminate\Validation\Concerns::ValidatesAttributes
-  Methods:  82.98% (78/94)   Lines:  95.20% (357/375)
+  Methods:  82.98% (78/94)   Lines:  95.21% (358/376)
 \Illuminate\Validation\Rules::DatabaseRule
   Methods:  60.00% ( 6/10)   Lines:  73.91% ( 17/ 23)
 \Illuminate\Validation\Rules::Illuminate\Validation\Rules\Dimensions
@@ -1247,9 +1247,9 @@
 \Illuminate\View::Illuminate\View\Factory
   Methods:  82.35% (28/34)   Lines:  86.67% ( 78/ 90)
 \Illuminate\View::Illuminate\View\FileViewFinder
-  Methods:  38.89% ( 7/18)   Lines:  61.54% ( 32/ 52)
+  Methods:  61.11% (11/18)   Lines:  76.92% ( 40/ 52)
 \Illuminate\View::Illuminate\View\View
-  Methods:  22.22% ( 6/27)   Lines:  40.00% ( 26/ 65)
+  Methods:  92.59% (25/27)   Lines:  93.85% ( 61/ 65)
 \Illuminate\View::Illuminate\View\ViewName
   Methods: 100.00% ( 1/ 1)   Lines: 100.00% (  5/  5)
 \Illuminate\View::Illuminate\View\ViewServiceProvider
@@ -1275,7 +1275,7 @@
 \Illuminate\View\Compilers\Concerns::CompilesLayouts
   Methods:  88.89% ( 8/ 9)   Lines:  92.31% ( 12/ 13)
 \Illuminate\View\Compilers\Concerns::CompilesLoops
-  Methods: 100.00% (12/12)   Lines: 100.00% ( 30/ 30)
+  Methods: 100.00% (12/12)   Lines: 100.00% ( 32/ 32)
 \Illuminate\View\Compilers\Concerns::CompilesRawPhp
   Methods: 100.00% ( 2/ 2)   Lines: 100.00% (  4/  4)
 \Illuminate\View\Compilers\Concerns::CompilesStacks
@@ -1287,9 +1287,9 @@
 \Illuminate\View\Concerns::ManagesEvents
   Methods:  81.82% ( 9/11)   Lines:  92.31% ( 36/ 39)
 \Illuminate\View\Concerns::ManagesLayouts
-  Methods:  75.00% ( 9/12)   Lines:  90.70% ( 39/ 43)
+  Methods:  83.33% (10/12)   Lines:  95.35% ( 41/ 43)
 \Illuminate\View\Concerns::ManagesLoops
-  Methods:  80.00% ( 4/ 5)   Lines:  96.00% ( 24/ 25)
+  Methods: 100.00% ( 5/ 5)   Lines: 100.00% ( 25/ 25)
 \Illuminate\View\Concerns::ManagesStacks
   Methods:  25.00% ( 2/ 8)   Lines:  54.76% ( 23/ 42)
 \Illuminate\View\Concerns::ManagesTranslations

The inaccuracies inherited from phpdbg are now gone, pcov and xdebug will generate as near as makes no difference the same report ... there is still a very slight difference in how pcov and xdebug handle switches, in that pcov is now using a compiler flag (when available, it was committed this morning) that suppresses the emission of jump tables for switches where expr is long/string so that it may report on the coverage inside the switch block correctly. This means the switch opcode is not generated and so the switch() line will not be seen as executable by pcov.

@krakjoe
Copy link
Contributor Author

krakjoe commented Jan 25, 2019

I've made an awful mess here, so closing and opening a clean PR with sensible commits ... sorry about all the noise ...

@krakjoe krakjoe closed this Jan 25, 2019
@krakjoe krakjoe deleted the pcov branch January 25, 2019 06:26
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.

4 participants