Skip to content

Commit 1ff0fc9

Browse files
committed
Add database test suite
Signed-off-by: Yuki Kishimoto <[email protected]>
1 parent 7cea9b1 commit 1ff0fc9

File tree

8 files changed

+879
-845
lines changed

8 files changed

+879
-845
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ jobs:
3535
- nostr-blossom
3636
- nostr-http-file-storage
3737
- nostr-database
38+
- nostr-database-test-suite
3839
- nostr-gossip
3940
- nostr-gossip-memory
4041
- nostr-gossip-test-suite

Cargo.lock

Lines changed: 9 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ members = [
44

55
# Nostr Database
66
"database/nostr-database",
7+
"database/nostr-database-test-suite",
78
"database/nostr-indexeddb",
89
"database/nostr-lmdb",
910
"database/nostr-ndb",
@@ -44,6 +45,7 @@ negentropy = { version = "0.5", default-features = false }
4445
nostr = { version = "0.44", path = "./crates/nostr", default-features = false }
4546
nostr-connect = { version = "0.44", path = "./signer/nostr-connect", default-features = false }
4647
nostr-database = { version = "0.44", path = "./database/nostr-database", default-features = false }
48+
nostr-database-test-suite = { path = "./database/nostr-database-test-suite" }
4749
nostr-gossip = { version = "0.44", path = "./gossip/nostr-gossip", default-features = false }
4850
nostr-gossip-memory = { version = "0.44", path = "./gossip/nostr-gossip-memory", default-features = false }
4951
nostr-gossip-test-suite = { path = "./gossip/nostr-gossip-test-suite" }

contrib/scripts/check-crates.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ buildargs=(
3434
"-p nostr-blossom"
3535
"-p nostr-http-file-storage"
3636
"-p nostr-database"
37+
"-p nostr-database-test-suite"
3738
"-p nostr-gossip"
3839
"-p nostr-gossip-memory"
3940
"-p nostr-gossip-test-suite"
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
[package]
2+
name = "nostr-database-test-suite"
3+
version = "0.1.0"
4+
edition = "2021"
5+
publish = false
6+
7+
[dependencies]
8+
nostr-database.workspace = true
9+
tokio = { workspace = true, features = ["macros", "rt-multi-thread"] }

database/nostr-database-test-suite/src/lib.rs

Lines changed: 852 additions & 0 deletions
Large diffs are not rendered by default.

database/nostr-lmdb/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,5 +28,6 @@ heed = { version = "0.20", default-features = false, features = ["read-txn-no-tl
2828

2929
[dev-dependencies]
3030
futures = "0.3"
31+
nostr-database-test-suite.workspace = true
3132
tempfile.workspace = true
3233
tokio = { workspace = true, features = ["macros", "rt-multi-thread"] }

database/nostr-lmdb/src/lib.rs

Lines changed: 4 additions & 845 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)