> ## Documentation Index
> Fetch the complete documentation index at: https://docs.synpress.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Function: defineWalletSetup()

```ts theme={null}
function defineWalletSetup(walletPassword, fn): {
  "fn": WalletSetupFunction;
  "hash": string;
  "walletPassword": string;
}
```

This function is used to define how a wallet should be set up.
Based on the contents of this function, a browser with the wallet extension is set up and cached so that it can be used by the tests later.

## Parameters

| Parameter        | Type                  | Description                                    |
| :--------------- | :-------------------- | :--------------------------------------------- |
| `walletPassword` | `string`              | The password of the wallet.                    |
| `fn`             | `WalletSetupFunction` | A function describing the setup of the wallet. |

## Returns

```ts theme={null}
{
  "fn": WalletSetupFunction;
  "hash": string;
  "walletPassword": string;
}
```

An object containing the hash of the function, the function itself, and the wallet password. The `testWithWalletSetup` function uses this object.

| Member           | Type                  |
| :--------------- | :-------------------- |
| `fn`             | `WalletSetupFunction` |
| `hash`           | `string`              |
| `walletPassword` | `string`              |
