hive_ce_test 2.0.0 copy "hive_ce_test: ^2.0.0" to clipboard
hive_ce_test: ^2.0.0 copied to clipboard

Initialize a temporary Hive database for testing

hive_ce_test #

Initialize a temporary Hive CE database for testing

Pub Version GitHub GitHub Workflow Status Coverage Status

🚀 Installation #

Install from pub.dev:

dev_dependencides:
  hive_ce_test: ^2.0.0

🔨 Usage #

In your test's setUp method, simply run:

setUp(() async {
  await setUpTestHive();
});

Then, in the tearDown method:

tearDown(() async {
  await tearDownTestHive();
});

Under the hood, this is a real instance of Hive CE. So you can open boxes, perform read/write transactions etc just as you would in an app!

👨🏻‍💻 Authors #

0
likes
140
points
846
downloads

Documentation

API reference

Publisher

verified publishersolusibejo.com

Weekly Downloads

Initialize a temporary Hive database for testing

Repository (GitHub)

License

MIT (license)

Dependencies

flutter, hive_ce, path

More

Packages that depend on hive_ce_test