From 7ca0cb86d0447a3b9509988c9f01df9a45797f7c Mon Sep 17 00:00:00 2001 From: Greg Littlefield Date: Tue, 3 Oct 2023 17:10:34 -0700 Subject: [PATCH] Clean up cast --- test/js_builds/shared_tests.dart | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/js_builds/shared_tests.dart b/test/js_builds/shared_tests.dart index 078c1dde..eea90ee4 100644 --- a/test/js_builds/shared_tests.dart +++ b/test/js_builds/shared_tests.dart @@ -7,6 +7,7 @@ import 'dart:js_util'; import 'package:js/js.dart'; import 'package:react/react.dart' as react; +import 'package:react/react_client/component_factory.dart'; import 'package:react/react_dom.dart' as react_dom; import 'package:react/react_client/react_interop.dart'; import 'package:test/test.dart'; @@ -172,7 +173,7 @@ void sharedErrorBoundaryComponentNameTests() { test('Component components', () { expectRenderErrorWithComponentName( - _ThrowingComponent({}) as ReactElement, + _ThrowingComponent({}), expectedComponentName: r'DisplayName$_ThrowingComponent', ); }); @@ -220,7 +221,8 @@ class _ErrorBoundaryComponent extends react.Component2 { } } -final _ThrowingComponent = react.registerComponent(() => _ThrowingComponentComponent()); +final _ThrowingComponent = + react.registerComponent(() => _ThrowingComponentComponent()) as ReactDartComponentFactoryProxy; class _ThrowingComponentComponent extends react.Component { @override