@@ -24,6 +24,7 @@ var paths = {
24
24
testResults : 'jsonResult.php' ,
25
25
locations : 'getLocations.php' ,
26
26
testers : 'getTesters.php' ,
27
+ testBalance : 'testBalance.php' ,
27
28
test : 'runtest.php' ,
28
29
gzip : 'getgzip.php' ,
29
30
har : 'export.php' ,
@@ -315,6 +316,17 @@ function getTesters(options, callback) {
315
316
return api . call ( this , paths . testers , callback , query , options ) ;
316
317
}
317
318
319
+ function getTestBalance ( options , callback ) {
320
+ callback = callback || options ;
321
+ options = options === callback ? undefined : options ;
322
+
323
+ var query = helper . setQuery ( mapping . commands . testBalance , options ) ;
324
+ if ( ! query . k && this . config . key ) {
325
+ query . k = this . config . key ;
326
+ }
327
+ return api . call ( this , paths . testBalance , callback , query , options ) ;
328
+ }
329
+
318
330
function runTest ( what , options , callback ) {
319
331
var query = { } ;
320
332
@@ -778,6 +790,7 @@ WebPageTest.prototype = {
778
790
restartTest : restartTest ,
779
791
cancelTest : cancelTest ,
780
792
getPageSpeedData : getPageSpeedData ,
793
+ getTestBalance : getTestBalance ,
781
794
getHARData : getHARData ,
782
795
getUtilizationData : getUtilizationData ,
783
796
getRequestData : getRequestData ,
0 commit comments