Skip to content

Commit 2fc55ab

Browse files
committed
lightbox test: Skip a no-hero test, pending rework for new page transitions
This test relies on background assumptions about how the "back" page transition work which are true of the current default transitions on Android (the default target platform of tests), but are broken by the upcoming introduction of predictive back: flutter/flutter#165832 (comment) For a quick unblocking of the upstream change, skip the test. In principle there's no reason a test like this can't work with the upcoming upstream behavior; it'll just need to work a little differently. But leave that for a follow-up change.
1 parent a1246ee commit 2fc55ab

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

test/widgets/lightbox_test.dart

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,7 @@ void main() {
275275
});
276276

277277
testWidgets('no hero animation occurs between different message list pages for same image', (tester) async {
278+
// Regression test for: https://github.com/zulip/zulip-flutter/issues/930
278279
Rect getElementRect(Element element) =>
279280
tester.getRect(find.byElementPredicate((e) => e == element));
280281

@@ -310,7 +311,13 @@ void main() {
310311
}
311312

312313
debugNetworkImageHttpClientProvider = null;
313-
});
314+
}, skip: true, // TODO get this no-hero test to work again with new page transitions;
315+
// see https://github.com/flutter/flutter/pull/165832#issuecomment-3111641360 .
316+
// Perhaps specify the old default, of ZoomPageTransitionsBuilder?
317+
// Or make getElementRect work relative to the enclosing page,
318+
// rather than the whole screen, so that the test becomes robust to
319+
// the whole pages moving around.
320+
);
314321
});
315322

316323
group('_ImageLightboxPage', () {

0 commit comments

Comments
 (0)