UNPKG

@j0nnyboi/amman

Version:

A modern mandatory toolbelt to help test solana SDK libraries and apps on a locally running validator.

31 lines (30 loc) 982 B
import { Amman } from '@j0nnyboi/amman-client'; import { TransactionError } from '@safecoin/web3.js'; import { Cluster } from './program-names'; export declare type LogMessage = { text: string; prefix: string; count?: number[]; style: 'muted' | 'info' | 'success' | 'warning'; }; export declare type InstructionLogs = { logs: LogMessage[]; failed: boolean; }; export declare class PrettyLogger { readonly amman?: Amman | undefined; readonly prettyLogs: InstructionLogs[]; instructionCount: number[]; depth: number; constructor(amman?: Amman | undefined); private incDepth; private decDepth; private incInstructionCount; private resetCount; addLine(line: string, error: TransactionError | null, cluster: Cluster): Promise<{ newLogs: LogMessage[]; newInstruction: boolean; newOuterInstruction: boolean; }>; prettyProgramLabel(programAddress: string, cluster: Cluster): Promise<string>; }