Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • SwitchboardTestContext

Implements

Index

Constructors

Properties

mint: Token
program: Program<Idl>
tokenWallet: PublicKey

Methods

  • updateStaticFeed(aggregatorAccount: AggregatorAccount, value: number, timeout?: number): Promise<void>
  • Update a feed to a single job that resolves to a new expected value

    Parameters

    • aggregatorAccount: AggregatorAccount

      the aggregator to change a job definition for

    • value: number

      the new expected value

    • timeout: number = 30

      how long to wait for the oracle to update the aggregator's latestRound result

    Returns Promise<void>

  • createSwitchboardWallet(program: Program<Idl>, amount?: number): Promise<PublicKey>
  • Parameters

    • program: Program<Idl>
    • amount: number = 1_000_000

    Returns Promise<PublicKey>

  • Load SwitchboardTestContext from an env file containing $SWITCHBOARD_PROGRAM_ID, $ORACLE_QUEUE, $AGGREGATOR, $ORACLE

    Parameters

    • provider: default

      anchor Provider containing connection and payer Keypair

    • filePath: string

      filesystem path to env file

    Returns Promise<SwitchboardTestContext>

Generated using TypeDoc