@waku/rln
Version:
RLN (Rate Limiting Nullifier) implementation for Waku
27 lines (26 loc) • 827 B
TypeScript
import { ethers } from "ethers";
import sinon from "sinon";
import type { IdentityCredential } from "../identity.js";
import { RLNContract } from "./rln_contract.js";
export interface TestRLNInstance {
rlnInstance: any;
identity: IdentityCredential;
insertMemberSpy: sinon.SinonStub;
}
/**
* Creates a test RLN instance with basic setup
*/
export declare function createTestRLNInstance(): Promise<TestRLNInstance>;
/**
* Initializes an RLN contract with the given registry contract
*/
export declare function initializeRLNContract(rlnInstance: any, mockedRegistryContract: ethers.Contract): Promise<RLNContract>;
/**
* Common test message data
*/
export declare const TEST_DATA: {
contentTopic: string;
emptyPubsubTopic: string;
testMessage: Uint8Array<ArrayBuffer>;
mockSignature: string;
};