-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
initial public api spec #299
base: main
Are you sure you want to change the base?
Conversation
Also relevant are questions about renaming "database" to "document" in which case what do we call the return of Candidate names are |
await db.destroy(); | ||
}); | ||
|
||
beforeEach(async function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
async () =>
doc = await db.get("test"); | ||
query = await db.query<string, Doc>((doc) => doc.foo); | ||
}); | ||
it("should be a database instance", function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
function =>
// erase the existing test data | ||
await sthis.start(); | ||
|
||
db = DatabaseFactory("test-reopen-spec", { autoCompact: 100000 }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why not fireproof?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice
i would go for this:
|
I like the suggestion of |
Please add the iterator and readstream api to alldocs/query. |
This is the test we expect all versions of 1.x to pass. If we break this test, we are talking about 2.0
Let's review and discuss before we merge. These are the main feature areas to specify:
db.query()
,db.allDocs()
,db.changes()
anddb.subscribe()
can be normalized.doc._id
are implicitly specified here, we can do better_proof
or something similar to give access to the underlying Merkle integrityAdding assertions (not removing them) from this test is how we know we are getting close to a new 1.1, 1.2, etc