| Index: chrome/test/data/webui/test_api.js
|
| diff --git a/chrome/test/data/webui/test_api.js b/chrome/test/data/webui/test_api.js
|
| index 04e7d4df84511d6a30979238387e7b35bd9baa5b..724b7634ada21905b525d3eeec61845889a131c9 100644
|
| --- a/chrome/test/data/webui/test_api.js
|
| +++ b/chrome/test/data/webui/test_api.js
|
| @@ -888,7 +888,7 @@ var testing = {};
|
| * @private
|
| */
|
| function runAccessibilityAudit(a11yErrors, a11yWarnings) {
|
| - var auditResults = axs.Audit.run();
|
| + var auditResults = axs.Audit.run(this.auditConfig);
|
| for (var i = 0; i < auditResults.length; i++) {
|
| var auditResult = auditResults[i];
|
| if (auditResult.result == axs.constants.AuditResult.FAIL) {
|
| @@ -975,11 +975,13 @@ var testing = {};
|
|
|
| /**
|
| * Asserts that the current page state passes the accessibility audit.
|
| + * @param {Array=} opt_errors Array to fill with errors, if desired.
|
| + * @param {Array=} opt_warnings Array to fill with warnings, if desired.
|
| */
|
| - function assertAccessibilityOk() {
|
| + function assertAccessibilityOk(opt_errors, opt_warnings) {
|
| helper.registerCall();
|
| - var a11yErrors = [];
|
| - var a11yWarnings = [];
|
| + var a11yErrors = opt_errors || [];
|
| + var a11yWarnings = opt_warnings || [];
|
| if (!runAccessibilityAudit(a11yErrors, a11yWarnings))
|
| throw new Error(accessibilityAuditReport(a11yErrors, a11yWarnings));
|
| }
|
|
|