*Update class name
This commit is contained in:
parent
a1d826e376
commit
a7a3ac1d03
6
test.js
6
test.js
|
@ -3,7 +3,7 @@ const test = require("tape");
|
||||||
const Hyperswarm = require("hyperswarm");
|
const Hyperswarm = require("hyperswarm");
|
||||||
const sodium = require("sodium-universal");
|
const sodium = require("sodium-universal");
|
||||||
const b4a = require("b4a");
|
const b4a = require("b4a");
|
||||||
const { default: DHTOnline } = require("./");
|
const { default: DHTData } = require("./");
|
||||||
const crypto = require("crypto");
|
const crypto = require("crypto");
|
||||||
const topicName = crypto.randomBytes(10);
|
const topicName = crypto.randomBytes(10);
|
||||||
const topic = b4a.allocUnsafe(32);
|
const topic = b4a.allocUnsafe(32);
|
||||||
|
@ -19,8 +19,8 @@ test("Basic presence test / data propagation", (t) => {
|
||||||
const peer1 = peers.shift();
|
const peer1 = peers.shift();
|
||||||
const peer2 = peers.shift();
|
const peer2 = peers.shift();
|
||||||
|
|
||||||
const p1 = new DHTOnline(peer1);
|
const p1 = new DHTData(peer1);
|
||||||
const p2 = new DHTOnline(peer2);
|
const p2 = new DHTData(peer2);
|
||||||
|
|
||||||
p1.data = { message: "Hello" };
|
p1.data = { message: "Hello" };
|
||||||
p2.data = { message: "World!" };
|
p2.data = { message: "World!" };
|
||||||
|
|
Loading…
Reference in New Issue