Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes: #1
Most of these fixtures are from js-dag-pb and go-dag-pb and some of them are even inherited from older dag-pb implementations. They test basic forms and some specific (tricky) edge cases.
For the fixtures that are dag-pb specific data model forms (
{ Data: bytes, Links: [...] }
), we now have the fixtures and their correct CIDs in the 3 different codecs being tested here. So for each version we decode it into the data model form, encode what we've ended up with with each of the 3 codecs and check that the CIDs match. So we get pretty good coverage of both decode and encode and the ability of implementations to properly represent the data model forms in memory.For Go: pulls in github.com/ipld/go-codec-dagpb, make the codec mapping more generic and remove hardwiring of most instances of dagjson and dagpb. Now better set up for pulling in arbitrary codecs in both JS & Go.