Skip to content

Commit

Permalink
Test to check if nodeBags is set
Browse files Browse the repository at this point in the history
  • Loading branch information
SoujanyaPonnapalli committed Apr 21, 2019
1 parent 5e58509 commit 998fe58
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1001,7 +1001,7 @@ describe('Test nodeCount', async () => {
});

describe('Test batchCOW with nodeBag on CachedMerkleTree', async () => {
const cache = new CachedMerklePatriciaTree<Buffer, Buffer>();
const cache = new CachedMerklePatriciaTree<Buffer, Buffer>({putCanDelete: false}, 1);
const value = Buffer.from('1234');
const updatedValue = Buffer.from('1234');
const nodesUsed = new Set<bigint>();
Expand Down Expand Up @@ -1058,4 +1058,8 @@ describe('Test batchCOW with nodeBag on CachedMerkleTree', async () => {
v2.should.deep.equal(updatedValue);
v3.should.deep.equal(updatedValue);
});

it('batchCOWwithNodeBag should set nodes used', async () => {
nodesUsed.size.should.not.equal(0);
})
});

0 comments on commit 998fe58

Please sign in to comment.