ssbc / ssb-tribes2

SSB private groups with ssb-db2
8 stars 1 forks source link

In crash-resistance tests, use secret opts that make the functions crash at certain points #107

Open Powersource opened 1 year ago

Powersource commented 1 year ago

Instead of trying to replicate how things probably look after a crash

for instance in create.test.js we have hacky code that partially creates a group.

mix suggested at some point (and i think this is probably better now that i've run into some weird test errors due to mismatch (due to updates of the function) between how the function and the emulation works) to use secret opts. something like

create(opts, cb) {
...
createGroupFeed((err, feed) => {
  if (err || opts._crashOnCreateGroupFeed) return cb(err)