| Index: third_party/WebKit/LayoutTests/mojo/binding.html
|
| diff --git a/third_party/WebKit/LayoutTests/mojo/binding.html b/third_party/WebKit/LayoutTests/mojo/binding.html
|
| index f04de81efb751d602118da27daf51cac19a48805..e65fda0fcce6734d91eb9e5a7fbc2f2826bfbf9a 100644
|
| --- a/third_party/WebKit/LayoutTests/mojo/binding.html
|
| +++ b/third_party/WebKit/LayoutTests/mojo/binding.html
|
| @@ -82,6 +82,22 @@ binding_test(async (bindings, math) => {
|
| var calcBinding = new bindings.Binding(math.Calculator,
|
| new CalculatorImpl(),
|
| bindings.makeRequest(calc));
|
| +
|
| + await new Promise((resolve, reject) => {
|
| + calcBinding.setConnectionErrorHandler(({custom_reason, description}) => {
|
| + assert_equals(custom_reason, 32);
|
| + assert_equals(description, 'goodbye');
|
| + resolve();
|
| + });
|
| + calc.ptr.resetWithReason({custom_reason: 32, description: 'goodbye'});
|
| + });
|
| +}, 'connection error with reason');
|
| +
|
| +binding_test(async (bindings, math) => {
|
| + var calc = new math.CalculatorPtr();
|
| + var calcBinding = new bindings.Binding(math.Calculator,
|
| + new CalculatorImpl(),
|
| + bindings.makeRequest(calc));
|
| assert_equals((await calc.add(2)).value, 2);
|
|
|
| var interfaceRequest = calcBinding.unbind();
|
|
|