UNPKG

jsonld-signatures-merkleproof2019

Version:

A jsonld signature implementation to support MerkleProof2019 verification in Verifiable Credential context

21 lines (19 loc) 632 B
import { describe, it, expect } from 'vitest'; import fixture from '../fixtures/mocknet-v3'; import { LDMerkleProof2019 } from '../../src'; describe('Given the test chain is Mocknet', function () { describe('when the certificate is valid', function () { it('should verify successfully', async function () { const instance = new LDMerkleProof2019({ document: fixture, proof: fixture.proof[1] // merkle proof }); const result = await instance.verifyProof(); expect(result).toEqual({ verified: true, verificationMethod: null, error: '' }); }); }); });