feat: add more gesture interceptors (#757)

This commit is contained in:
Mathias Mogensen 2024-04-04 13:51:05 +02:00 • committed by GitHub
commit c97842ae91
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 59 additions and 14 deletions

View file

@ -1,9 +1,11 @@
import 'dart:io';
import 'package:appflowy_editor/appflowy_editor.dart';
import 'package:flutter/services.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:appflowy_editor/appflowy_editor.dart';
import '../../../../infra/clipboard_test.dart';
import '../../../infra/testable_editor.dart';
@ -40,12 +42,12 @@ void main() async {
(tester) async {
await _testHandleCopy(tester, Document.fromJson(data));
});
testWidgets(
'Presses Command + A in nested document and copy text nestednode',
(tester) async {
// TODO: fix this test
// await _testNestedNodeCopyPaste(tester, Document.fromJson(exampledoc));
});
// TODO: fix this test
// testWidgets(
// 'Presses Command + A in nested document and copy text nestednode',
// (tester) async {
// await _testNestedNodeCopyPaste(tester, Document.fromJson(exampledoc));
// });
testWidgets('update selection and execute cut command', (tester) async {
await _testCutHandle(tester, Document.fromJson(cutData));

View file

@ -1,7 +1,9 @@
import 'package:appflowy_editor/appflowy_editor.dart';
import 'package:flutter/services.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:appflowy_editor/appflowy_editor.dart';
import '../../../infra/testable_editor.dart';
const _padding = 24.0;
@ -103,8 +105,8 @@ void main() async {
});
// TODO(.): The purpose of this test is to catch addPostFrameCallback from
// calculateTextDirection but it doesn't catch it. Commenting the callback
// out doesn't make this test fail.
// calculateTextDirection but it doesn't catch it. Commenting the callback
// out doesn't make this test fail.
testWidgets(
"indent AUTO line under AUTO line changing the second line calculated direction",
(tester) async {