throw exception in benchmark class if one has not been defined.
This commit is contained in:
parent
ab08987247
commit
72e7275fe0
|
|
@ -33,7 +33,7 @@ public static function check($name)
|
|||
return number_format((microtime(true) - static::$marks[$name]) * 1000, 2);
|
||||
}
|
||||
|
||||
return 0.0;
|
||||
throw new \Exception("A Benchmark named [$name] has not been started.");
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in New Issue