@auser/pmem
TypeScript icon, indicating that this package has built-in type declarations

0.1.12 • Public • Published

pmem

Want to run some database driven tests? So did we... but testing against a database between isolated tests is hard. That's where pmem comes into play.

Usage

First create an instance of the database system:

const db = new Database()
await db.start();

When you want to create a new database, run new_db():

const new_uri = await db.new_db();

When you're done with the database, kill it:

await db.stop(new_uri);

When you're done, clean up!

await db.cleanup();

TODO

  • [ ] Change database creation into it's own instance
  • [ ] Explore using vectors of DBLocks

Readme

Keywords

none

Package Sidebar

Install

npm i @auser/pmem

Weekly Downloads

0

Version

0.1.12

License

ISC

Unpacked Size

7.49 MB

Total Files

18

Last publish

Collaborators

  • auser