drift/extras/integration_tests
Simon Binder e07397006f
Remove SelectableUtils extension
2021-01-20 12:06:48 +01:00
..
ffi_on_flutter Setup CI with Dart 2.12 beta 2020-11-18 10:53:20 +01:00
moor_flutter Split ffi & sqflite integration tests 2020-07-23 12:27:45 +02:00
tests Remove SelectableUtils extension 2021-01-20 12:06:48 +01:00
vm Support older versions of the convert package too 2020-11-26 16:59:06 +01:00
web Migrate integration tests to DatabaseConnection 2020-04-25 15:12:55 +02:00
README.md

README.md

Integration tests

These directories contain integration tests for the various moor backends by running the same set of actions on multiple databases.

Tests

All test cases live in tests/lib. We have a runAllTests method that basically takes a QueryExecutor (the database backend in moor) and then runs all tests on that executor. Everything the other packages are doing is calling the runAllTests method with the database they're supposed to test.


Flutter is a bit annoying here because AFAIK there is no easy way to run tests that run on a real device? With flutter drive, the tests are still run on a local machine which communicates with an app to verify behavior of widgets. As we want to run the whole test bundle on a device, we instead put the test files into flutter_db/lib and run them with flutter run. That works, but we don't get an output format that is machine readable. Please create an issue if you know a better way, thanks! TODO: https://github.com/tomaszpolanski/flutter-presentations/blob/master/lib/test_driver/test_runner.dart looks promising

That is also why these tests are not running automatically.