diff --git a/README.md b/README.md index 5ff37d4..03f9a25 100644 --- a/README.md +++ b/README.md @@ -43,6 +43,8 @@ Awesome Flutter Snippets is a collection of commonly used Flutter classes and me | `cupeapp` | Cupertino Package | Create a New Cupertino App. | `tweenAnimationBuilder` | Tween Animation Builder | Widget builder that animates a property of a Widget to a target value whenever the target value changes. | `valueListenableBuilder` | Value Listenable Builder | Given a ValueListenable and a builder which builds widgets from concrete values of T, this class will automatically register itself as a listener of the ValueListenable and call the builder with updated values when the value changes. +| `f-test` | Test | Create a test function. +| `f-testWidgets` | Test Widgets | Create a testWidgets function.
diff --git a/snippets/snippets.json b/snippets/snippets.json index eaa53c7..f81e271 100644 --- a/snippets/snippets.json +++ b/snippets/snippets.json @@ -418,5 +418,25 @@ " )," ], "description": "Given a ValueListenable and a builder which builds widgets from concrete values of T, this class will automatically register itself as a listener of the ValueListenable and call the builder with updated values when the value changes." + }, + "Test": { + "prefix": "f-test", + "body": [ + "test(", + " \"${1:test description}\",", + " () {},", + ");" + ], + "description": "Create a test function" + }, + "Test Widgets": { + "prefix": "f-testWidgets", + "body": [ + "testWidgets(", + " \"${1:test description}\",", + " (WidgetTester tester) async {},", + ");" + ], + "description": "Create a testWidgets function" } }