test: pass keypair instead of privkey for test cases

Tests were not building due to recent changes in the Damus source code that replaced privkey with keypair. This patch extends those changes to the test cases, allowing the tests to build and pass.

Signed-off-by: Jon Marrs <jdmarrs@gmail.com>
Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
Jon Marrs
2023-08-30 16:22:04 -07:00
committed by William Casarin
parent c71b0ee916
commit dd29e87146
5 changed files with 15 additions and 15 deletions

View File

@@ -150,7 +150,7 @@ final class NdbTests: XCTestCase {
return
}
self.measure(options: longer_iter()) {
let blocks = event.blocks(nil).blocks
let blocks = event.blocks(test_keypair).blocks
let xs = interpret_event_refs(blocks: blocks, tags: event.tags)
XCTAssertEqual(xs.count, 1)
}
@@ -161,7 +161,7 @@ final class NdbTests: XCTestCase {
return
}
self.measure(options: longer_iter()) {
let blocks = note.blocks(nil).blocks
let blocks = note.blocks(test_keypair).blocks
let xs = interpret_event_refs_ndb(blocks: blocks, tags: note.tags)
XCTAssertEqual(xs.count, 1)
}
@@ -180,8 +180,8 @@ final class NdbTests: XCTestCase {
XCTAssertEqual(note.pubkey, event.pubkey)
XCTAssertEqual(note.id, event.id)
let ev_blocks = event.blocks(nil)
let note_blocks = note.blocks(nil)
let ev_blocks = event.blocks(test_keypair)
let note_blocks = note.blocks(test_keypair)
XCTAssertEqual(ev_blocks, note_blocks)