diff --git a/tests/lib/html/js_typed_interop_type2_test.dart b/tests/lib/html/js_typed_interop_type2_test.dart
index fd3ebfdbcd3..cb4681f1db1 100644
--- a/tests/lib/html/js_typed_interop_type2_test.dart
+++ b/tests/lib/html/js_typed_interop_type2_test.dart
@@ -12,7 +12,7 @@ import 'package:expect/expect.dart';
@JS()
@anonymous
class C {
- late final foo;
+ external get foo;
external factory C({required foo});
}
@@ -20,7 +20,7 @@ class C {
@JS()
@anonymous
class D {
- late final foo;
+ external get foo;
external factory D({required foo});
}
diff --git a/tests/lib/html/js_typed_interop_type3_test.dart b/tests/lib/html/js_typed_interop_type3_test.dart
index 5e0ff0f55b5..d764182bb81 100644
--- a/tests/lib/html/js_typed_interop_type3_test.dart
+++ b/tests/lib/html/js_typed_interop_type3_test.dart
@@ -19,7 +19,7 @@ class A {
@JS()
@anonymous
class C {
- late final foo;
+ external get foo;
external factory C({required foo});
}
@@ -27,7 +27,7 @@ class C {
@JS()
@anonymous
class D {
- late final foo;
+ external get foo;
external factory D({required foo});
}