You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Mar 10, 2020. It is now read-only.
test(dag): add test to verify put API overrides hash algorithm (#323)
As discussed in ipfs/js-ipfs#1419 (comment)
at the time of this commit, `dag.put()` basically ignores the `hashAlg`
option, as it passes it down to `ipld.put()`, which won't honor it until
ipld/js-ipld#133 is merged.
Once ipld/js-ipld#133 is merged, this test verifies
that e.g.
```
dag.put(cborNode, {
format: 'dag-cbor',
hashAlg: 'sha3-512'
}, (err, cid) => {
...
})
```
Actually results in a `CID` instance that decodes to `sha3-512` and not
the `sha2-256` default.
License: MIT
Signed-off-by: Pascal Precht pascal.precht@gmail.com
0 commit comments