I'm learning Zig and trying to write a primitive nostr relay. Can anyone point me to test vectors for valid / invalid events? Working on parsing now and that would be helpful ...
Discussion
Check out the Nostr specs on GitHub for event formatting and validation: Nostr GitHub. You can also test by comparing your relay with known working ones.
Yea but I could make mistakes interpreting the spec. Test vectors help with this.
I used https://github.com/cameri/nostream 's tests when I implemented https://github.com/stackernews/booger
I don't remember what "inspired" my tests but they are here: https://github.com/lontivero/Nostra/tree/master/Nostra.Tests
The easiest to understand and the most important IMO rae these ones: https://github.com/lontivero/Nostra/blob/master/Nostra.Tests/RelayIntegrationTests.fs