File tree Expand file tree Collapse file tree 4 files changed +22
-2
lines changed
Expand file tree Collapse file tree 4 files changed +22
-2
lines changed Original file line number Diff line number Diff line change @@ -384,15 +384,15 @@ public function detectsDeadCode(): bool
384384 */
385385 public function driverIsPcov (): bool
386386 {
387- return $ this ->driver instanceof PcovDriver ;
387+ return $ this ->driver -> isPcov () ;
388388 }
389389
390390 /**
391391 * @internal
392392 */
393393 public function driverIsXdebug (): bool
394394 {
395- return $ this ->driver instanceof XdebugDriver ;
395+ return $ this ->driver -> isXdebug () ;
396396 }
397397
398398 /**
Original file line number Diff line number Diff line change @@ -120,6 +120,16 @@ public function disableDeadCodeDetection(): void
120120 $ this ->detectDeadCode = false ;
121121 }
122122
123+ public function isPcov (): bool
124+ {
125+ return false ;
126+ }
127+
128+ public function isXdebug (): bool
129+ {
130+ return false ;
131+ }
132+
123133 abstract public function nameAndVersion (): string ;
124134
125135 abstract public function start (): void ;
Original file line number Diff line number Diff line change @@ -68,6 +68,11 @@ public function nameAndVersion(): string
6868 return 'PCOV ' . phpversion ('pcov ' );
6969 }
7070
71+ public function isPcov (): true
72+ {
73+ return true ;
74+ }
75+
7176 /**
7277 * @throws PcovNotAvailableException
7378 */
Original file line number Diff line number Diff line change @@ -125,6 +125,11 @@ public function nameAndVersion(): string
125125 return 'Xdebug ' . phpversion ('xdebug ' );
126126 }
127127
128+ public function isXdebug (): true
129+ {
130+ return true ;
131+ }
132+
128133 /**
129134 * @throws XdebugNotAvailableException
130135 */
You can’t perform that action at this time.
0 commit comments