| Index: third_party/WebKit/LayoutTests/http/tests/budget/get-budget.html
|
| diff --git a/third_party/WebKit/LayoutTests/http/tests/budget/get-budget.html b/third_party/WebKit/LayoutTests/http/tests/budget/get-budget.html
|
| index 92839ea2bd93c71e684a6b61337407037f59b58e..1b1758c4a379ab1c3eba73424f87c336d9122d5b 100644
|
| --- a/third_party/WebKit/LayoutTests/http/tests/budget/get-budget.html
|
| +++ b/third_party/WebKit/LayoutTests/http/tests/budget/get-budget.html
|
| @@ -15,6 +15,7 @@
|
| promise_test(function() {
|
| return budgetServiceMock.then(mock => {
|
| assert_own_property(Navigator.prototype, 'budget');
|
| + mock.addBudget(TEST_BUDGET_TIME, TEST_BUDGET_AT);
|
| return navigator.budget.getBudget();
|
| }).then(budget => {
|
| assert_equals(budget.length, 1);
|
| @@ -22,6 +23,19 @@
|
| assert_equals(budget[0].time, TEST_BUDGET_TIME);
|
| });
|
| }, 'BudgetService.GetBudget should return correct results.');
|
| +
|
| + promise_test(function() {
|
| + return budgetServiceMock.then(mock => {
|
| + assert_own_property(Navigator.prototype, 'budget');
|
| + mock.setError("database-error");
|
| + return navigator.budget.getBudget();
|
| + }).then(budget => {
|
| + assert_unreached('getBudget should have failed.');
|
| + }, function(error) {
|
| + assert_equals(error.name, 'DataError');
|
| + assert_equals(error.message, "Error reading the budget database.");
|
| + });
|
| + }, 'BudgetService.GetBudget should return correct results.');
|
| </script>
|
| </body>
|
| </html>
|
|
|