Skip to content

Instantly share code, notes, and snippets.

@olexale
Last active February 28, 2021 10:17
Show Gist options
  • Save olexale/da5761aee2c35982a45af795501209cf to your computer and use it in GitHub Desktop.
Save olexale/da5761aee2c35982a45af795501209cf to your computer and use it in GitHub Desktop.
BDD in Flutter article code generated files
// GENERATED CODE - DO NOT MODIFY BY HAND
// ignore_for_file: unused_import, directives_ordering
import 'package:flutter/material.dart';
import 'package:flutter_test/flutter_test.dart';
import './step/the_app_is_running.dart';
import './step/i_see_text.dart';
void main() {
group('Counter', () {
testWidgets('Initial counter value is 0', (tester) async {
await theAppIsRunning(tester);
await iSeeText(tester, '0');
});
});
}
import 'package:flutter_test/flutter_test.dart';
Future<void> iSeeText(WidgetTester tester, String text) async {
expect(find.text(text), findsOneWidget);
}
import 'package:flutter_test/flutter_test.dart';
import 'package:bdd_showcase_app/main.dart';
Future<void> theAppIsRunning(WidgetTester tester) async {
await tester.pumpWidget(MyApp());
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment