basic datstore checks

This commit is contained in:
Jaremy Creechley 2023-08-28 19:55:05 -07:00
parent 0f0a85a046
commit f0e79a696e
No known key found for this signature in database
GPG Key ID: 4E66FB67B21D3300

View File

@ -3,7 +3,7 @@ import std/sequtils
import std/algorithm
import std/locks
import std/os
import pkg/stew/byteutils
import pkg/unittest2
import pkg/questionable
import pkg/questionable/results
@ -95,12 +95,16 @@ suite "Share buffer test":
check a == b
test "toString":
check a.toString() == "/a/b"
test "key conversion":
check a.toKey().get() == k1
test "hash":
check a.hash() == b.hash()
test "hashes differ":
check a.hash() != c.hash()
test "key conversion":
check a.toKey().get() == k1
test "seq conversion":
check a.toSeq(char) == @"/a/b"
test "seq conversion":
check a.toSeq(byte) == "/a/b".toBytes
test "basic thread test":
runBasicTest()