mirror of https://github.com/AMT-Cheif/drift.git
Explain how to install sqlite for moor_ffi unit tests
This commit is contained in:
parent
0667191f14
commit
71ef36ff83
|
@ -52,6 +52,17 @@ class MyDatabase extends _$MyDatabase {
|
|||
}
|
||||
```
|
||||
|
||||
{{% alert title="Installing sqlite" %}}
|
||||
We can't distribute an sqlite installation as a pub package (at least
|
||||
not as something that works outside of a Flutter build), so you need
|
||||
to ensure that you have the sqlite3 shared library installed on your
|
||||
system. On macOS, it's installed by default. On Linux, you can use the
|
||||
`libsqlite3-dev` package on Ubuntu and the `sqlite3` package on Arch
|
||||
(other distros will have similar packages). I'm not sure how it works
|
||||
on Windows, but [downloading sqlite](https://www.sqlite.org/download.html)
|
||||
and extracting `sqlite3.dll` into your application folder might work.
|
||||
{{% /alert %}}
|
||||
|
||||
## Writing tests
|
||||
|
||||
We can create an in-memory version of the database by using a
|
||||
|
|
Loading…
Reference in New Issue