File tree Expand file tree Collapse file tree 1 file changed +29
-0
lines changed
Expand file tree Collapse file tree 1 file changed +29
-0
lines changed Original file line number Diff line number Diff line change @@ -180,6 +180,20 @@ public function getTestedMethodsPercent(bool $asString = true)
180180 );
181181 }
182182
183+ /**
184+ * Returns the percentage of paths that have been tested.
185+ *
186+ * @return int|string
187+ */
188+ public function getPathsTestedPercent (bool $ asString = true )
189+ {
190+ return Util::percent (
191+ $ this ->getNumTestedPaths (),
192+ $ this ->getNumPaths (),
193+ $ asString
194+ );
195+ }
196+
183197 /**
184198 * Returns the percentage of functions and methods that has been tested.
185199 *
@@ -276,6 +290,11 @@ abstract public function getFunctions(): array;
276290 */
277291 abstract public function getLinesOfCode (): array ;
278292
293+ /**
294+ * Returns the paths of this node.
295+ */
296+ abstract public function getPaths (): array ;
297+
279298 /**
280299 * Returns the number of executable lines.
281300 */
@@ -325,4 +344,14 @@ abstract public function getNumFunctions(): int;
325344 * Returns the number of tested functions.
326345 */
327346 abstract public function getNumTestedFunctions (): int ;
347+
348+ /**
349+ * Returns the number of paths.
350+ */
351+ abstract public function getNumPaths (): int ;
352+
353+ /**
354+ * Returns the number of tested paths.
355+ */
356+ abstract public function getNumTestedPaths (): int ;
328357}
You can’t perform that action at this time.
0 commit comments