Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
868ff428
Unverified
Commit
868ff428
authored
Jan 07, 2019
by
Alexandre Ardhuin
Committed by
GitHub
Jan 07, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix doc-comment snippets (#25579)
parent
e54e53c1
Changes
22
Hide whitespace changes
Inline
Side-by-side
Showing
22 changed files
with
107 additions
and
98 deletions
+107
-98
known_broken_documentation.dart
...ze-sample-code-test-input/known_broken_documentation.dart
+1
-1
custom_a11y_traversal.dart
examples/catalog/lib/custom_a11y_traversal.dart
+12
-12
app.dart
packages/flutter/lib/src/material/app.dart
+6
-6
bottom_navigation_bar.dart
packages/flutter/lib/src/material/bottom_navigation_bar.dart
+35
-35
button_theme.dart
packages/flutter/lib/src/material/button_theme.dart
+1
-0
icon_button.dart
packages/flutter/lib/src/material/icon_button.dart
+1
-1
typography.dart
packages/flutter/lib/src/material/typography.dart
+2
-1
decoration.dart
packages/flutter/lib/src/painting/decoration.dart
+1
-1
image_provider.dart
packages/flutter/lib/src/painting/image_provider.dart
+2
-2
image_resolution.dart
packages/flutter/lib/src/painting/image_resolution.dart
+2
-2
binding.dart
packages/flutter/lib/src/scheduler/binding.dart
+1
-1
icon.dart
packages/flutter/lib/src/widgets/icon.dart
+4
-4
image.dart
packages/flutter/lib/src/widgets/image.dart
+2
-2
navigator.dart
packages/flutter/lib/src/widgets/navigator.dart
+12
-12
platform_view.dart
packages/flutter/lib/src/widgets/platform_view.dart
+6
-0
scroll_controller.dart
packages/flutter/lib/src/widgets/scroll_controller.dart
+5
-5
scroll_physics.dart
packages/flutter/lib/src/widgets/scroll_physics.dart
+1
-0
text.dart
packages/flutter/lib/src/widgets/text.dart
+0
-1
mock_canvas.dart
packages/flutter/test/rendering/mock_canvas.dart
+1
-1
semantics_tester.dart
packages/flutter/test/widgets/semantics_tester.dart
+1
-0
driver.dart
packages/flutter_driver/lib/src/driver/driver.dart
+6
-6
widget_tester.dart
packages/flutter_test/lib/src/widget_tester.dart
+5
-5
No files found.
dev/bots/test/analyze-sample-code-test-input/known_broken_documentation.dart
View file @
868ff428
...
@@ -39,5 +39,5 @@
...
@@ -39,5 +39,5 @@
/// new Opacity(
/// new Opacity(
/// opacity: _visible ? 1.0 : 0.0,
/// opacity: _visible ? 1.0 : 0.0,
/// child: const Text('Poor wandering ones!'),
/// child: const Text('Poor wandering ones!'),
/// )
,
/// )
/// ```
/// ```
examples/catalog/lib/custom_a11y_traversal.dart
View file @
868ff428
...
@@ -59,18 +59,18 @@ class RowColumnTraversal extends StatelessWidget {
...
@@ -59,18 +59,18 @@ class RowColumnTraversal extends StatelessWidget {
/// This function expresses the sort keys as a hierarchy, but it could just as
/// This function expresses the sort keys as a hierarchy, but it could just as
/// easily have been a flat list:
/// easily have been a flat list:
///
///
/// ```
/// ```
dart
///
Widget build(BuildContext context) {
/// Widget build(BuildContext context) {
///
return new Semantics(
/// return new Semantics(
///
sortOrder: new SemanticsSortOrder(
/// sortOrder: new SemanticsSortOrder(
///
keys: <SemanticsSortKey>[
/// keys: <SemanticsSortKey>[
///
new OrdinalSortKey(columnOrder.toDouble()),
/// new OrdinalSortKey(columnOrder.toDouble()),
///
new OrdinalSortKey(rowOrder.toDouble())
/// new OrdinalSortKey(rowOrder.toDouble())
///
],
/// ],
///
),
/// ),
///
child: child,
/// child: child,
///
);
/// );
///
}
/// }
/// ```
/// ```
///
///
/// The resulting order is the same.
/// The resulting order is the same.
...
...
packages/flutter/lib/src/material/app.dart
View file @
868ff428
...
@@ -181,12 +181,12 @@ class MaterialApp extends StatefulWidget {
...
@@ -181,12 +181,12 @@ class MaterialApp extends StatefulWidget {
/// ```dart
/// ```dart
/// import 'package:flutter_localizations/flutter_localizations.dart';
/// import 'package:flutter_localizations/flutter_localizations.dart';
/// MaterialApp(
/// MaterialApp(
/// localizationsDelegates: [
///
localizationsDelegates: [
/// // ... app-specific localization delegate[s] here
///
// ... app-specific localization delegate[s] here
/// GlobalMaterialLocalizations.delegate,
///
GlobalMaterialLocalizations.delegate,
/// GlobalWidgetsLocalizations.delegate,
///
GlobalWidgetsLocalizations.delegate,
/// ],
///
],
/// supportedLocales: [
///
supportedLocales: [
/// const Locale('en', 'US'), // English
/// const Locale('en', 'US'), // English
/// const Locale('he', 'IL'), // Hebrew
/// const Locale('he', 'IL'), // Hebrew
/// // ... other locales the app supports
/// // ... other locales the app supports
...
...
packages/flutter/lib/src/material/bottom_navigation_bar.dart
View file @
868ff428
...
@@ -79,47 +79,47 @@ enum BottomNavigationBarType {
...
@@ -79,47 +79,47 @@ enum BottomNavigationBarType {
///
///
/// ```dart
/// ```dart
/// class MyHomePage extends StatefulWidget {
/// class MyHomePage extends StatefulWidget {
/// MyHomePage({Key key}) : super(key: key);
///
MyHomePage({Key key}) : super(key: key);
///
///
/// @override
///
@override
/// _MyHomePageState createState() => _MyHomePageState();
///
_MyHomePageState createState() => _MyHomePageState();
/// }
/// }
///
///
/// class _MyHomePageState extends State<MyHomePage> {
/// class _MyHomePageState extends State<MyHomePage> {
/// int _selectedIndex = 1;
///
int _selectedIndex = 1;
/// final _widgetOptions = [
///
final _widgetOptions = [
/// Text('Index 0: Home'),
///
Text('Index 0: Home'),
/// Text('Index 1: Business'),
///
Text('Index 1: Business'),
/// Text('Index 2: School'),
///
Text('Index 2: School'),
/// ];
///
];
///
///
/// @override
///
@override
/// Widget build(BuildContext context) {
///
Widget build(BuildContext context) {
/// return Scaffold(
///
return Scaffold(
/// appBar: AppBar(
///
appBar: AppBar(
/// title: Text('BottomNavigationBar Sample'),
///
title: Text('BottomNavigationBar Sample'),
/// ),
///
),
/// body: Center(
///
body: Center(
/// child: _widgetOptions.elementAt(_selectedIndex),
///
child: _widgetOptions.elementAt(_selectedIndex),
/// ),
///
),
/// bottomNavigationBar: BottomNavigationBar(
///
bottomNavigationBar: BottomNavigationBar(
/// items: <BottomNavigationBarItem>[
///
items: <BottomNavigationBarItem>[
/// BottomNavigationBarItem(icon: Icon(Icons.home), title: Text('Home')),
///
BottomNavigationBarItem(icon: Icon(Icons.home), title: Text('Home')),
/// BottomNavigationBarItem(icon: Icon(Icons.business), title: Text('Business')),
///
BottomNavigationBarItem(icon: Icon(Icons.business), title: Text('Business')),
/// BottomNavigationBarItem(icon: Icon(Icons.school), title: Text('School')),
///
BottomNavigationBarItem(icon: Icon(Icons.school), title: Text('School')),
/// ],
///
],
/// currentIndex: _selectedIndex,
///
currentIndex: _selectedIndex,
/// fixedColor: Colors.deepPurple,
///
fixedColor: Colors.deepPurple,
/// onTap: _onItemTapped,
///
onTap: _onItemTapped,
/// ),
///
),
/// );
///
);
/// }
///
}
///
///
/// void _onItemTapped(int index) {
///
void _onItemTapped(int index) {
/// setState(() {
///
setState(() {
/// _selectedIndex = index;
///
_selectedIndex = index;
/// });
///
});
/// }
///
}
/// }
/// }
/// ```
/// ```
///
///
...
...
packages/flutter/lib/src/material/button_theme.dart
View file @
868ff428
...
@@ -265,6 +265,7 @@ class ButtonThemeData extends Diagnosticable {
...
@@ -265,6 +265,7 @@ class ButtonThemeData extends Diagnosticable {
/// Simply a convenience that returns [minWidth] and [height] as a
/// Simply a convenience that returns [minWidth] and [height] as a
/// [BoxConstraints] object:
/// [BoxConstraints] object:
///
/// ```dart
/// ```dart
/// return BoxConstraints(
/// return BoxConstraints(
/// minWidth: minWidth,
/// minWidth: minWidth,
...
...
packages/flutter/lib/src/material/icon_button.dart
View file @
868ff428
...
@@ -151,7 +151,7 @@ class IconButton extends StatelessWidget {
...
@@ -151,7 +151,7 @@ class IconButton extends StatelessWidget {
/// color: Colors.blue,
/// color: Colors.blue,
/// onPressed: _handleTap,
/// onPressed: _handleTap,
/// icon: Icons.widgets,
/// icon: Icons.widgets,
/// )
,
/// )
/// ```
/// ```
final
Color
color
;
final
Color
color
;
...
...
packages/flutter/lib/src/material/typography.dart
View file @
868ff428
...
@@ -68,7 +68,8 @@ enum ScriptCategory {
...
@@ -68,7 +68,8 @@ enum ScriptCategory {
/// `Typography(platform: platform)` which uses [englishLike2014],
/// `Typography(platform: platform)` which uses [englishLike2014],
/// [dense2014] and [tall2014]. To use the 2018 text theme
/// [dense2014] and [tall2014]. To use the 2018 text theme
/// geometries, specify a typography value:
/// geometries, specify a typography value:
/// ```
///
/// ```dart
/// Typography(
/// Typography(
/// platorm: platform,
/// platorm: platform,
/// englishLike: Typography.englishLike2018,
/// englishLike: Typography.englishLike2018,
...
...
packages/flutter/lib/src/painting/decoration.dart
View file @
868ff428
...
@@ -33,7 +33,7 @@ abstract class Decoration extends Diagnosticable {
...
@@ -33,7 +33,7 @@ abstract class Decoration extends Diagnosticable {
///
///
/// This is intended to be used as follows:
/// This is intended to be used as follows:
/// ```dart
/// ```dart
///
assert(myDecoration.debugAssertIsValid());
/// assert(myDecoration.debugAssertIsValid());
/// ```
/// ```
bool
debugAssertIsValid
()
=>
true
;
bool
debugAssertIsValid
()
=>
true
;
...
...
packages/flutter/lib/src/painting/image_provider.dart
View file @
868ff428
...
@@ -700,8 +700,8 @@ class MemoryImage extends ImageProvider<MemoryImage> {
...
@@ -700,8 +700,8 @@ class MemoryImage extends ImageProvider<MemoryImage> {
/// it in the `assets` section:
/// it in the `assets` section:
///
///
/// ```yaml
/// ```yaml
/// assets:
///
assets:
/// - packages/fancy_backgrounds/backgrounds/background1.png
///
- packages/fancy_backgrounds/backgrounds/background1.png
/// ```
/// ```
///
///
/// The `lib/` is implied, so it should not be included in the asset path.
/// The `lib/` is implied, so it should not be included in the asset path.
...
...
packages/flutter/lib/src/painting/image_resolution.dart
View file @
868ff428
...
@@ -111,8 +111,8 @@ const String _kAssetManifestFileName = 'AssetManifest.json';
...
@@ -111,8 +111,8 @@ const String _kAssetManifestFileName = 'AssetManifest.json';
/// it in the `assets` section:
/// it in the `assets` section:
///
///
/// ```yaml
/// ```yaml
/// assets:
///
assets:
/// - packages/fancy_backgrounds/backgrounds/background1.png
///
- packages/fancy_backgrounds/backgrounds/background1.png
/// ```
/// ```
///
///
/// The `lib/` is implied, so it should not be included in the asset path.
/// The `lib/` is implied, so it should not be included in the asset path.
...
...
packages/flutter/lib/src/scheduler/binding.dart
View file @
868ff428
...
@@ -513,7 +513,7 @@ mixin SchedulerBinding on BindingBase, ServicesBinding {
...
@@ -513,7 +513,7 @@ mixin SchedulerBinding on BindingBase, ServicesBinding {
/// To call this function, use the following code:
/// To call this function, use the following code:
///
///
/// ```dart
/// ```dart
///
SchedulerBinding.debugPrintTransientCallbackRegistrationStack();
/// SchedulerBinding.debugPrintTransientCallbackRegistrationStack();
/// ```
/// ```
static
void
debugPrintTransientCallbackRegistrationStack
()
{
static
void
debugPrintTransientCallbackRegistrationStack
()
{
assert
(()
{
assert
(()
{
...
...
packages/flutter/lib/src/widgets/icon.dart
View file @
868ff428
...
@@ -79,10 +79,10 @@ class Icon extends StatelessWidget {
...
@@ -79,10 +79,10 @@ class Icon extends StatelessWidget {
/// Typically, a material design color will be used, as follows:
/// Typically, a material design color will be used, as follows:
///
///
/// ```dart
/// ```dart
///
Icon(
/// Icon(
///
icon: Icons.widgets,
/// icon: Icons.widgets,
///
color: Colors.blue.shade400,
/// color: Colors.blue.shade400,
///
),
///
)
/// ```
/// ```
final
Color
color
;
final
Color
color
;
...
...
packages/flutter/lib/src/widgets/image.dart
View file @
868ff428
...
@@ -368,8 +368,8 @@ class Image extends StatefulWidget {
...
@@ -368,8 +368,8 @@ class Image extends StatefulWidget {
/// specify it in the assets section:
/// specify it in the assets section:
///
///
/// ```yaml
/// ```yaml
/// assets:
///
assets:
/// - packages/fancy_backgrounds/backgrounds/background1.png
///
- packages/fancy_backgrounds/backgrounds/background1.png
/// ```
/// ```
///
///
/// The `lib/` is implied, so it should not be included in the asset path.
/// The `lib/` is implied, so it should not be included in the asset path.
...
...
packages/flutter/lib/src/widgets/navigator.dart
View file @
868ff428
...
@@ -595,18 +595,18 @@ class NavigatorObserver {
...
@@ -595,18 +595,18 @@ class NavigatorObserver {
///
///
/// ```dart
/// ```dart
/// class MyApp extends StatelessWidget {
/// class MyApp extends StatelessWidget {
/// @override
///
@override
/// Widget build(BuildContext context) {
///
Widget build(BuildContext context) {
/// return MaterialApp(
///
return MaterialApp(
/// // ...some parameters omitted...
///
// ...some parameters omitted...
/// // MaterialApp contains our top-level Navigator
///
// MaterialApp contains our top-level Navigator
/// initialRoute: '/',
///
initialRoute: '/',
/// routes: {
///
routes: {
/// '/': (BuildContext context) => HomePage(),
///
'/': (BuildContext context) => HomePage(),
/// '/signup': (BuildContext context) => SignUpPage(),
///
'/signup': (BuildContext context) => SignUpPage(),
/// },
///
},
/// );
///
);
/// }
///
}
/// }
/// }
///
///
/// class SignUpPage extends StatelessWidget {
/// class SignUpPage extends StatelessWidget {
...
...
packages/flutter/lib/src/widgets/platform_view.dart
View file @
868ff428
...
@@ -117,6 +117,7 @@ class AndroidView extends StatefulWidget {
...
@@ -117,6 +117,7 @@ class AndroidView extends StatefulWidget {
///
///
/// For example, with the following setup vertical drags will not be dispatched to the Android
/// For example, with the following setup vertical drags will not be dispatched to the Android
/// view as the vertical drag gesture is claimed by the parent [GestureDetector].
/// view as the vertical drag gesture is claimed by the parent [GestureDetector].
///
/// ```dart
/// ```dart
/// GestureDetector(
/// GestureDetector(
/// onVerticalDragStart: (DragStartDetails d) {},
/// onVerticalDragStart: (DragStartDetails d) {},
...
@@ -125,8 +126,10 @@ class AndroidView extends StatefulWidget {
...
@@ -125,8 +126,10 @@ class AndroidView extends StatefulWidget {
/// ),
/// ),
/// )
/// )
/// ```
/// ```
///
/// To get the [AndroidView] to claim the vertical drag gestures we can pass a vertical drag
/// To get the [AndroidView] to claim the vertical drag gestures we can pass a vertical drag
/// gesture recognizer factory in [gestureRecognizers] e.g:
/// gesture recognizer factory in [gestureRecognizers] e.g:
///
/// ```dart
/// ```dart
/// GestureDetector(
/// GestureDetector(
/// onVerticalDragStart: (DragStartDetails details) {},
/// onVerticalDragStart: (DragStartDetails details) {},
...
@@ -247,6 +250,7 @@ class UiKitView extends StatefulWidget {
...
@@ -247,6 +250,7 @@ class UiKitView extends StatefulWidget {
///
///
/// For example, with the following setup vertical drags will not be dispatched to the UIKit
/// For example, with the following setup vertical drags will not be dispatched to the UIKit
/// view as the vertical drag gesture is claimed by the parent [GestureDetector].
/// view as the vertical drag gesture is claimed by the parent [GestureDetector].
///
/// ```dart
/// ```dart
/// GestureDetector(
/// GestureDetector(
/// onVerticalDragStart: (DragStartDetails details) {},
/// onVerticalDragStart: (DragStartDetails details) {},
...
@@ -255,8 +259,10 @@ class UiKitView extends StatefulWidget {
...
@@ -255,8 +259,10 @@ class UiKitView extends StatefulWidget {
/// ),
/// ),
/// )
/// )
/// ```
/// ```
///
/// To get the [UiKitView] to claim the vertical drag gestures we can pass a vertical drag
/// To get the [UiKitView] to claim the vertical drag gestures we can pass a vertical drag
/// gesture recognizer factory in [gestureRecognizers] e.g:
/// gesture recognizer factory in [gestureRecognizers] e.g:
///
/// ```dart
/// ```dart
/// GestureDetector(
/// GestureDetector(
/// onVerticalDragStart: (DragStartDetails details) {},
/// onVerticalDragStart: (DragStartDetails details) {},
...
...
packages/flutter/lib/src/widgets/scroll_controller.dart
View file @
868ff428
...
@@ -297,11 +297,11 @@ class ScrollController extends ChangeNotifier {
...
@@ -297,11 +297,11 @@ class ScrollController extends ChangeNotifier {
/// controller: _trackingScrollController,
/// controller: _trackingScrollController,
/// children: List<Widget>.generate(100, (int i) => Text('page 0 item $i')).toList(),
/// children: List<Widget>.generate(100, (int i) => Text('page 0 item $i')).toList(),
/// ),
/// ),
/// ListView(
///
ListView(
/// controller: _trackingScrollController,
///
controller: _trackingScrollController,
/// children: List<Widget>.generate(200, (int i) => Text('page 1 item $i')).toList(),
///
children: List<Widget>.generate(200, (int i) => Text('page 1 item $i')).toList(),
/// ),
///
),
/// ListView(
///
ListView(
/// controller: _trackingScrollController,
/// controller: _trackingScrollController,
/// children: List<Widget>.generate(300, (int i) => Text('page 2 item $i')).toList(),
/// children: List<Widget>.generate(300, (int i) => Text('page 2 item $i')).toList(),
/// ),
/// ),
...
...
packages/flutter/lib/src/widgets/scroll_physics.dart
View file @
868ff428
...
@@ -41,6 +41,7 @@ class ScrollPhysics {
...
@@ -41,6 +41,7 @@ class ScrollPhysics {
/// ScrollPhysics that has [ancestor] as its parent.
/// ScrollPhysics that has [ancestor] as its parent.
///
///
/// This method is typically used to define [applyTo] methods like:
/// This method is typically used to define [applyTo] methods like:
///
/// ```dart
/// ```dart
/// FooScrollPhysics applyTo(ScrollPhysics ancestor) {
/// FooScrollPhysics applyTo(ScrollPhysics ancestor) {
/// return FooScrollPhysics(parent: buildParent(ancestor));
/// return FooScrollPhysics(parent: buildParent(ancestor));
...
...
packages/flutter/lib/src/widgets/text.dart
View file @
868ff428
...
@@ -337,7 +337,6 @@ class Text extends StatelessWidget {
...
@@ -337,7 +337,6 @@ class Text extends StatelessWidget {
///
///
/// ```dart
/// ```dart
/// Text(r'$$', semanticsLabel: 'Double dollars')
/// Text(r'$$', semanticsLabel: 'Double dollars')
///
/// ```
/// ```
final
String
semanticsLabel
;
final
String
semanticsLabel
;
...
...
packages/flutter/test/rendering/mock_canvas.dart
View file @
868ff428
...
@@ -28,7 +28,7 @@ import 'recording_canvas.dart';
...
@@ -28,7 +28,7 @@ import 'recording_canvas.dart';
/// To specify the pattern, call the methods on the returned object. For example:
/// To specify the pattern, call the methods on the returned object. For example:
///
///
/// ```dart
/// ```dart
///
expect(myRenderObject, paints..circle(radius: 10.0)..circle(radius: 20.0));
/// expect(myRenderObject, paints..circle(radius: 10.0)..circle(radius: 20.0));
/// ```
/// ```
///
///
/// This particular pattern would verify that the render object `myRenderObject`
/// This particular pattern would verify that the render object `myRenderObject`
...
...
packages/flutter/test/widgets/semantics_tester.dart
View file @
868ff428
...
@@ -495,6 +495,7 @@ class SemanticsTester {
...
@@ -495,6 +495,7 @@ class SemanticsTester {
/// ));
/// ));
/// semantics.dispose();
/// semantics.dispose();
/// });
/// });
/// ```
///
///
/// At this point the unit test should automatically pass because it was
/// At this point the unit test should automatically pass because it was
/// generated from the actual [SemanticsNode]s. Next time the semantics tree
/// generated from the actual [SemanticsNode]s. Next time the semantics tree
...
...
packages/flutter_driver/lib/src/driver/driver.dart
View file @
868ff428
...
@@ -601,12 +601,12 @@ class FlutterDriver {
...
@@ -601,12 +601,12 @@ class FlutterDriver {
///
///
/// ```dart
/// ```dart
/// test('enters text in a text field', () async {
/// test('enters text in a text field', () async {
/// var textField = find.byValueKey('enter-text-field');
///
var textField = find.byValueKey('enter-text-field');
/// await driver.tap(textField); // acquire focus
///
await driver.tap(textField); // acquire focus
/// await driver.enterText('Hello!'); // enter text
///
await driver.enterText('Hello!'); // enter text
/// await driver.waitFor(find.text('Hello!')); // verify text appears on UI
///
await driver.waitFor(find.text('Hello!')); // verify text appears on UI
/// await driver.enterText('World!'); // enter another piece of text
///
await driver.enterText('World!'); // enter another piece of text
/// await driver.waitFor(find.text('World!')); // verify new text appears
///
await driver.waitFor(find.text('World!')); // verify new text appears
/// });
/// });
/// ```
/// ```
Future
<
void
>
enterText
(
String
text
,
{
Duration
timeout
})
async
{
Future
<
void
>
enterText
(
String
text
,
{
Duration
timeout
})
async
{
...
...
packages/flutter_test/lib/src/widget_tester.dart
View file @
868ff428
...
@@ -59,11 +59,11 @@ typedef WidgetTesterCallback = Future<void> Function(WidgetTester widgetTester);
...
@@ -59,11 +59,11 @@ typedef WidgetTesterCallback = Future<void> Function(WidgetTester widgetTester);
/// ## Sample code
/// ## Sample code
///
///
/// ```dart
/// ```dart
///
testWidgets('MyWidget', (WidgetTester tester) async {
/// testWidgets('MyWidget', (WidgetTester tester) async {
///
await tester.pumpWidget(new MyWidget());
/// await tester.pumpWidget(new MyWidget());
///
await tester.tap(find.text('Save'));
/// await tester.tap(find.text('Save'));
///
expect(find.text('Success'), findsOneWidget);
/// expect(find.text('Success'), findsOneWidget);
///
});
/// });
/// ```
/// ```
@isTest
@isTest
void
testWidgets
(
String
description
,
WidgetTesterCallback
callback
,
{
void
testWidgets
(
String
description
,
WidgetTesterCallback
callback
,
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment