Skip to content

Commit

Permalink
Get rid of unnecessary Flutter binding assertions in tests (#337)
Browse files Browse the repository at this point in the history
* Get rid of unnecessary Flutter binding assertion in tests

* Improve wording in README

* Remove streamable views task form README
  • Loading branch information
vitusortner authored May 23, 2020
1 parent 527b0cb commit 9fa2bb5
Show file tree
Hide file tree
Showing 9 changed files with 4 additions and 22 deletions.
6 changes: 2 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Floor provides a neat SQLite abstraction for your Flutter applications inspired by the [Room persistence library](https://developer.android.com/topic/libraries/architecture/room).
It comes with automatic mapping between in-memory objects and database rows while still offering full control of the database with the use of SQL.
In order to harvest Floor's full potential, it's necessary to have an understanding of SQL and SQLite.
As a consequence, it's necessary to have an understanding of SQL and SQLite in order to harvest Floor's full potential.

- typesafe
- reactive
Expand All @@ -13,7 +13,7 @@ In order to harvest Floor's full potential, it's necessary to have an understand
- iOS, Android, Linux, macOS, Windows

⚠️ The library is on its way to its first stable release!
After integrating type converters, embeddable objects and streamable database views, the API surface won't change until after 1.0.
After integrating type converters and embeddable objects, the API surface won't change until after 1.0.

[![pub package](https://img.shields.io/pub/v/floor.svg)](https://pub.dartlang.org/packages/floor)
[![build status](https://github.com/vitusortner/floor/workflows/Continuous%20integration/badge.svg)](https://github.com/vitusortner/floor/actions)
Expand Down Expand Up @@ -611,8 +611,6 @@ import 'database.dart';
import 'entity/person.dart';
void main() {
TestWidgetsFlutterBinding.ensureInitialized();
group('database tests', () {
TestDatabase database;
PersonDao personDao;
Expand Down
2 changes: 0 additions & 2 deletions example/test/main_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ import 'package:flutter/material.dart';
import 'package:flutter_test/flutter_test.dart';

void main() {
TestWidgetsFlutterBinding.ensureInitialized();

FlutterDatabase database;
TaskDao taskDao;

Expand Down
6 changes: 2 additions & 4 deletions floor/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Floor provides a neat SQLite abstraction for your Flutter applications inspired by the [Room persistence library](https://developer.android.com/topic/libraries/architecture/room).
It comes with automatic mapping between in-memory objects and database rows while still offering full control of the database with the use of SQL.
In order to harvest Floor's full potential, it's necessary to have an understanding of SQL and SQLite.
As a consequence, it's necessary to have an understanding of SQL and SQLite in order to harvest Floor's full potential.

- typesafe
- reactive
Expand All @@ -13,7 +13,7 @@ In order to harvest Floor's full potential, it's necessary to have an understand
- iOS, Android, Linux, macOS, Windows

⚠️ The library is on its way to its first stable release!
After integrating type converters, embeddable objects and streamable database views, the API surface won't change until after 1.0.
After integrating type converters and embeddable objects, the API surface won't change until after 1.0.

[![pub package](https://img.shields.io/pub/v/floor.svg)](https://pub.dartlang.org/packages/floor)
[![build status](https://github.com/vitusortner/floor/workflows/Continuous%20integration/badge.svg)](https://github.com/vitusortner/floor/actions)
Expand Down Expand Up @@ -611,8 +611,6 @@ import 'database.dart';
import 'entity/person.dart';
void main() {
TestWidgetsFlutterBinding.ensureInitialized();
group('database tests', () {
TestDatabase database;
PersonDao personDao;
Expand Down
2 changes: 0 additions & 2 deletions floor/test/integration/blob/blob_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ import 'package:sqflite/sqflite.dart' as sqflite;
part 'blob_test.g.dart';

void main() {
TestWidgetsFlutterBinding.ensureInitialized();

group('BLOB tests', () {
TestDatabase database;
PersonDao personDao;
Expand Down
2 changes: 0 additions & 2 deletions floor/test/integration/boolean_conversions/bool_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ import 'package:sqflite/sqflite.dart' as sqflite;
part 'bool_test.g.dart';

void main() {
TestWidgetsFlutterBinding.ensureInitialized();

group('Bool tests', () {
TestDatabase database;
BoolDao boolDao;
Expand Down
2 changes: 0 additions & 2 deletions floor/test/integration/database_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ import 'model/dog.dart';
import 'model/person.dart';

void main() {
TestWidgetsFlutterBinding.ensureInitialized();

group('database tests', () {
TestDatabase database;
PersonDao personDao;
Expand Down
2 changes: 0 additions & 2 deletions floor/test/integration/inheritance/dao_inheritance_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ import 'package:sqflite/sqflite.dart' as sqflite;
part 'dao_inheritance_test.g.dart';

void main() {
TestWidgetsFlutterBinding.ensureInitialized();

group('dao inheritance tests', () {
TestDatabase database;
PersonDao personDao;
Expand Down
2 changes: 0 additions & 2 deletions floor/test/integration/stream_query_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ import 'model/dog.dart';
import 'model/person.dart';

void main() {
TestWidgetsFlutterBinding.ensureInitialized();

group('stream query tests', () {
TestDatabase database;
PersonDao personDao;
Expand Down
2 changes: 0 additions & 2 deletions floor/test/integration/view/view_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@ abstract class ViewTestDatabase extends FloorDatabase {
}

void main() {
TestWidgetsFlutterBinding.ensureInitialized();

group('database tests', () {
ViewTestDatabase database;
PersonDao personDao;
Expand Down

0 comments on commit 9fa2bb5

Please sign in to comment.