# Testing

<figure><img src="/files/zzy5UkQ0iWYip9dhSSwZ" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
The test suite was migrated to Forge upon migration to LensV3. Not all tests are included on Github yet. The following provides instructions for running the LensV2 test suite.
{% endhint %}

A comprehensive Test Suite for the SDK and Contract Suite is located in the `test` folder in the root of the project. Before running the tests, you will need to compile the project and set up your environment variables.

### **Kinora Contract Suite and SDK Test**

{% hint style="warning" %}
comment out this part of the **KinoraOpenAction** contract before running the test suite or an error will throw. It is only a required check once deployed.

```solidity
!MODULE_GLOBALS.isErc20CurrencyRegistered(
       _params.milestones[i].rewards[j].tokenAddress
          )
  ) {
    revert KinoraErrors.CurrencyNotWhitelisted();
 }
```

{% endhint %}

{% hint style="info" %}
The SDK is being continuously updated to include additional features and configurations, if a contract test is not passing, it could be due to a discrepency in the test suite and the latest SDK version. Please let us know if you find anything!
{% endhint %}

To run the contract and node Sequence tests, place a valid `PRIVATE_KEY` in your root `.env` file to create the signer object for transacting within the hardhat local network.

```sh
PRIVATE_KEY=
```

Run the following in your command line:

```bash
npm run test
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://codex.irrevocable.dev/resources/testing.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
