Update view counter test for publish return

This commit is contained in:
thePR0M3TH3AN committed 2025-10-01 18:21:47 -04:00
1 parent b0774de823
commit 63274d4c43
1 file changed
+6 -2
+6 -2
View File
@@ -577,7 +577,11 @@ async function testRecordVideoViewEmitsJsonPayload() {
};
nostrClient.pubkey = "";
nostrClient.updateWatchHistoryList = async () => ({ ok: true });
nostrClient.updateWatchHistoryList = async () => {
throw new Error(
"recordVideoView should not invoke updateWatchHistoryList during view publishes"
);
};
try {
const result = await nostrClient.recordVideoView(pointer, {
@@ -614,7 +618,7 @@ async function testRecordVideoViewEmitsJsonPayload() {
);
assert.equal(
result.view.event.content,
result.event.content,
emittedEvent.content,
"serialized payload should persist on the emitted event"
);