entropic-dev / entropic-dev/boltzmann

Allow nesting of middleware.test functions

Open
#83 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
8
Forks
5
PR merge metrics
No merged PRs in 30d

Description

This would allow for the following:

```js
tap.test('Frobnicators', _(async assert => {
var frob
tap.beforeEach(() => {
frob = Frob.objects.create({...}) // recreated per-test in this test handler
})

tap.test('should frob evenly', _(async assert => {
Frob.objects.filter({id: frob.id}).update({...}) // changes discarded before next test
})
}))
```

Specifically we should track if we're in a test so we can use `CHECKPOINT` / `ROLLBACK TO CHECKPOINT` to persist _some_ changes in the db. Redis... we'll continue to drop entirely between tests.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.