main_test.dart 929 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10
// Copyright 2014 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

import 'package:flutter_driver/flutter_driver.dart';
import 'package:test/test.dart' hide TypeMatcher, isInstanceOf;

void main() {
  test('Windows app starts and draws frame', () async {
    final FlutterDriver driver = await FlutterDriver.connect(printCommunication: true);
11 12 13 14 15 16 17 18 19 20
    final String result = await driver.requestData('verifyWindowVisibility');

    expect(result, equals('success'));

    await driver.close();
  }, timeout: Timeout.none);

  test('Windows app theme matches system theme', () async {
    final FlutterDriver driver = await FlutterDriver.connect(printCommunication: true);
    final String result = await driver.requestData('verifyTheme');
21 22 23 24 25 26

    expect(result, equals('success'));

    await driver.close();
  }, timeout: Timeout.none);
}