Skip to content

Commit

Permalink
[battery] Bump version for NNBD stable (flutter#3594)
Browse files Browse the repository at this point in the history
Also replaces Mockito with test/Fake since the usage is a simple fake.
  • Loading branch information
stuartmorgan authored and adsonpleal committed Feb 26, 2021
1 parent 8b182e9 commit e7191e7
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 13 deletions.
2 changes: 1 addition & 1 deletion packages/battery/battery/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## 2.0.0-nullsafety
## 2.0.0

* Migrate to null safety.

Expand Down
4 changes: 2 additions & 2 deletions packages/battery/battery/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ dev_dependencies:
sdk: flutter
integration_test:
path: ../../../integration_test
pedantic: ^1.10.0-nullsafety
pedantic: ^1.10.0

flutter:
uses-material-design: true

environment:
sdk: ">=2.12.0-0 <3.0.0"
sdk: ">=2.12.0-259.9.beta <3.0.0"
flutter: ">=1.12.13+hotfix.5"
14 changes: 7 additions & 7 deletions packages/battery/battery/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: battery
description: Flutter plugin for accessing information about the battery state
(full, charging, discharging) on Android and iOS.
homepage: https://github.com/flutter/plugins/tree/master/packages/battery/battery
version: 2.0.0-nullsafety
version: 2.0.0

flutter:
plugin:
Expand All @@ -16,18 +16,18 @@ flutter:
dependencies:
flutter:
sdk: flutter
meta: ^1.3.0-nullsafety
battery_platform_interface: ^2.0.0-nullsafety
meta: ^1.3.0
battery_platform_interface: ^2.0.0

dev_dependencies:
mockito: ^5.0.0-nullsafety.0
flutter_test:
sdk: flutter
plugin_platform_interface: ^1.1.0-nullsafety
plugin_platform_interface: ">=1.0.0 <3.0.0"
integration_test:
path: ../../integration_test
pedantic: ^1.10.0-nullsafety
pedantic: ^1.10.0
test: ^1.16.3

environment:
sdk: ">=2.12.0-0 <3.0.0"
sdk: ">=2.12.0-259.9.beta <3.0.0"
flutter: ">=1.12.13+hotfix.5"
6 changes: 3 additions & 3 deletions packages/battery/battery/test/battery_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@

import 'dart:async';

import 'package:battery/battery.dart';
import 'package:battery_platform_interface/battery_platform_interface.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:plugin_platform_interface/plugin_platform_interface.dart';
import 'package:battery/battery.dart';
import 'package:mockito/mockito.dart';
import 'package:test/fake.dart';

void main() {
group('battery', () {
Expand All @@ -30,7 +30,7 @@ void main() {
});
}

class MockBatteryPlatform extends Mock
class MockBatteryPlatform extends Fake
with MockPlatformInterfaceMixin
implements BatteryPlatform {
Future<int> batteryLevel() async {
Expand Down

0 comments on commit e7191e7

Please sign in to comment.