title: flutter automatic testing : Tap on a button don't work in drawer
body: <p>I'm trying to do some TDD with flutter and when the test is running,  tapping on a button doesn't work if it's in a drawer. The button works perfectly fine with a normal user.</p>
  
  <p>In the following example we press on two buttons which print a message in the console. Here's the actions :<br>
  locate and tap on a button in the scaffold: OK<br>
  open the drawer: OK<br>
  Locate button in drawer: OK<br>
  Tap on the drawer button: <strong>nothing happen</strong>  </p>
  
  <pre><code>import 'package:flutter/material.dart';
  import 'package:flutter_test/flutter_test.dart';
  
  void main() {
    testWidgets('Test that drawer is apparing and we can click on button',
    (WidgetTester tester) async {
  final scaffoldKey = GlobalKey&lt;ScaffoldState&gt;();
  
  await tester.pumpWidget(new MaterialApp(
    title: 'Where Assistant',
    home: Scaffold(
      key: scaffoldKey,
      body: Column(
        children: &lt;Widget&gt;[
          Text('test text'),
          RaisedButton(
            onPressed: () {
              print('OK on main screen');
            },
            child: Icon(Icons.access_alarm),
          ),
        ],
      ),
      drawer: Drawer(
        // Add a ListView to the drawer. This ensures the user can scroll
        // through the options in the Drawer if there isn't enough vertical
        // space to fit everything.
        child: ListView(
          // Important: Remove any padding from the ListView.
          padding: EdgeInsets.zero,
          children: &lt;Widget&gt;[
            DrawerHeader(
              child: Text('Drawer Header'),
              decoration: BoxDecoration(
                color: Colors.blue,
              ),
            ),
            ListTile(
              title: Text('Item 2'),
              onTap: () {
                // Update the state of the app
                // ...
              },
            ),
            RaisedButton(
              onPressed: () {
                print('OK drawer');
              },
              child: Icon(Icons.add),
            )
          ],
        ),
      ),
    ),
  ));
  
  await tester.pump();
  
  expect(find.text('test text'), findsOneWidget);
  expect(find.byIcon(Icons.access_alarm), findsOneWidget);
  await tester.tap(find.byIcon(Icons.access_alarm));
  expect(find.byIcon(Icons.add), findsNothing);
  
  scaffoldKey.currentState.openDrawer();
  await tester.pump(); // drawer should appear
  
  expect(find.text('Item 2'), findsOneWidget);
  expect(find.byIcon(Icons.add), findsOneWidget);
  await tester.tap(find.byIcon(Icons.add));
  print('end of test');
    });
  }
  </code></pre>