migrate e2e test to integration test (#744)

pull/677/head
Ayush Bherwani 4 years ago committed by GitHub
parent 3b2a7121ca
commit 6c81510d6e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1,11 +1,11 @@
# federated_plugin_web
A flutter plugin to provide location support for web. The web implementation
of `federated_plugin` is tested using [e2e](https://pub.dev/packages/e2e) package.
of `federated_plugin` is tested using [integration_test](https://pub.dev/packages/integration_test) package.
### Steps to run e2e test on browser
### Steps to run integration test on browser
- Download and install the ChromeDriver from [here](https://chromedriver.chromium.org/downloads)
for the version of Chrome you are using.
- Start the driver using `chromedrive --port=4444`
- Run the test using `flutter drive -d web-server --release --browser-name=chrome --target=test_driver/federated_plugin_web_e2e.dart`
- Run the test using `flutter drive -d web-server --browser-name=chrome --release --target=test_driver/federated_plugin_web_integration.dart`

@ -7,21 +7,21 @@ packages:
name: _fe_analyzer_shared
url: "https://pub.dartlang.org"
source: hosted
version: "12.0.0"
version: "14.0.0"
analyzer:
dependency: transitive
description:
name: analyzer
url: "https://pub.dartlang.org"
source: hosted
version: "0.40.6"
version: "0.41.2"
archive:
dependency: transitive
description:
name: archive
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.13"
version: "3.0.0"
args:
dependency: transitive
description:
@ -35,21 +35,21 @@ packages:
name: async
url: "https://pub.dartlang.org"
source: hosted
version: "2.5.0-nullsafety.3"
version: "2.5.0"
boolean_selector:
dependency: transitive
description:
name: boolean_selector
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.0-nullsafety.3"
version: "2.1.0"
build:
dependency: transitive
description:
name: build
url: "https://pub.dartlang.org"
source: hosted
version: "1.6.0"
version: "1.6.2"
built_collection:
dependency: transitive
description:
@ -70,14 +70,14 @@ packages:
name: characters
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0-nullsafety.5"
version: "1.1.0"
charcode:
dependency: transitive
description:
name: charcode
url: "https://pub.dartlang.org"
source: hosted
version: "1.2.0-nullsafety.3"
version: "1.2.0"
cli_util:
dependency: transitive
description:
@ -91,7 +91,7 @@ packages:
name: clock
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0-nullsafety.3"
version: "1.1.0"
code_builder:
dependency: transitive
description:
@ -105,7 +105,7 @@ packages:
name: collection
url: "https://pub.dartlang.org"
source: hosted
version: "1.15.0-nullsafety.5"
version: "1.15.0"
convert:
dependency: transitive
description:
@ -119,7 +119,7 @@ packages:
name: crypto
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.5"
version: "3.0.0"
dart_style:
dependency: transitive
description:
@ -127,20 +127,13 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "1.3.10"
e2e:
dependency: "direct dev"
description:
name: e2e
url: "https://pub.dartlang.org"
source: hosted
version: "0.7.0+1"
fake_async:
dependency: transitive
description:
name: fake_async
url: "https://pub.dartlang.org"
source: hosted
version: "1.2.0-nullsafety.3"
version: "1.2.0"
federated_plugin_platform_interface:
dependency: "direct main"
description:
@ -154,7 +147,7 @@ packages:
name: file
url: "https://pub.dartlang.org"
source: hosted
version: "6.0.0-nullsafety.4"
version: "6.1.0"
fixnum:
dependency: transitive
description:
@ -194,20 +187,20 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "1.2.0"
js:
dependency: transitive
integration_test:
dependency: "direct dev"
description:
name: js
name: integration_test
url: "https://pub.dartlang.org"
source: hosted
version: "0.6.3-nullsafety.3"
json_rpc_2:
version: "1.0.2+2"
js:
dependency: transitive
description:
name: json_rpc_2
name: js
url: "https://pub.dartlang.org"
source: hosted
version: "2.2.2"
version: "0.6.3"
logging:
dependency: transitive
description:
@ -221,21 +214,21 @@ packages:
name: matcher
url: "https://pub.dartlang.org"
source: hosted
version: "0.12.10-nullsafety.3"
version: "0.12.10"
meta:
dependency: transitive
description:
name: meta
url: "https://pub.dartlang.org"
source: hosted
version: "1.3.0-nullsafety.6"
version: "1.3.0"
mockito:
dependency: "direct dev"
description:
name: mockito
url: "https://pub.dartlang.org"
source: hosted
version: "4.1.3"
version: "4.1.4"
node_interop:
dependency: transitive
description:
@ -263,7 +256,7 @@ packages:
name: path
url: "https://pub.dartlang.org"
source: hosted
version: "1.8.0-nullsafety.3"
version: "1.8.0"
pedantic:
dependency: "direct dev"
description:
@ -277,7 +270,7 @@ packages:
name: platform
url: "https://pub.dartlang.org"
source: hosted
version: "3.0.0-nullsafety.4"
version: "3.0.0"
plugin_platform_interface:
dependency: transitive
description:
@ -291,7 +284,7 @@ packages:
name: process
url: "https://pub.dartlang.org"
source: hosted
version: "4.0.0-nullsafety.4"
version: "4.1.0"
pub_semver:
dependency: transitive
description:
@ -324,70 +317,70 @@ packages:
name: source_span
url: "https://pub.dartlang.org"
source: hosted
version: "1.8.0-nullsafety.4"
version: "1.8.1"
stack_trace:
dependency: transitive
description:
name: stack_trace
url: "https://pub.dartlang.org"
source: hosted
version: "1.10.0-nullsafety.6"
version: "1.10.0"
stream_channel:
dependency: transitive
description:
name: stream_channel
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.0-nullsafety.3"
version: "2.1.0"
string_scanner:
dependency: transitive
description:
name: string_scanner
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0-nullsafety.3"
version: "1.1.0"
sync_http:
dependency: transitive
description:
name: sync_http
url: "https://pub.dartlang.org"
source: hosted
version: "0.2.0"
version: "0.3.0"
term_glyph:
dependency: transitive
description:
name: term_glyph
url: "https://pub.dartlang.org"
source: hosted
version: "1.2.0-nullsafety.3"
version: "1.2.0"
test_api:
dependency: transitive
description:
name: test_api
url: "https://pub.dartlang.org"
source: hosted
version: "0.2.19-nullsafety.6"
version: "0.2.19"
typed_data:
dependency: transitive
description:
name: typed_data
url: "https://pub.dartlang.org"
source: hosted
version: "1.3.0-nullsafety.5"
version: "1.3.0"
vector_math:
dependency: transitive
description:
name: vector_math
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.0-nullsafety.5"
version: "2.1.0"
vm_service:
dependency: transitive
description:
name: vm_service
url: "https://pub.dartlang.org"
source: hosted
version: "5.5.0"
version: "6.0.1-nullsafety.1"
watcher:
dependency: transitive
description:
@ -395,20 +388,13 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "0.9.7+15"
web_socket_channel:
dependency: transitive
description:
name: web_socket_channel
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0"
webdriver:
dependency: transitive
description:
name: webdriver
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.2"
version: "3.0.0"
yaml:
dependency: transitive
description:
@ -418,4 +404,4 @@ packages:
version: "2.2.1"
sdks:
dart: ">=2.12.0-0.0 <3.0.0"
flutter: ">=1.17.0 <2.0.0"
flutter: ">=1.17.0"

@ -19,8 +19,8 @@ dependencies:
dev_dependencies:
flutter_test:
sdk: flutter
integration_test: ^1.0.1
pedantic: ^1.9.0
e2e: ^0.7.0
mockito: ^4.1.1
flutter:

@ -4,9 +4,9 @@
import 'dart:html';
import 'package:e2e/e2e.dart';
import 'package:federated_plugin_web/federated_plugin_web.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:integration_test/integration_test.dart';
import 'package:mockito/mockito.dart';
const kBatteryLevel = 0.49;
@ -19,7 +19,7 @@ class BatteryManagerMock extends Mock implements BatteryManager {
}
void main() {
E2EWidgetsFlutterBinding.ensureInitialized();
IntegrationTestWidgetsFlutterBinding.ensureInitialized();
group('FederatedPlugin test', () {
final navigatorMock = NavigatorMock();

@ -4,6 +4,7 @@
import 'dart:async';
import 'package:e2e/e2e_driver.dart' as e2e;
import 'package:integration_test/integration_test_driver.dart';
Future<void> main() async => e2e.main();
Future<void> main() async => integrationDriver();
Loading…
Cancel
Save