This guide provides step-by-step instructions for setting up and running tests for the Eclipse Program Library.
-
Clone the repository:
git clone https://github.com/rarible/eclipse-program-library.git cd eclipse-program-library
-
Install dependencies:
yarn install
-
Sync program IDs:
- Open
Anchor.toml
andconstants.ts
- Ensure that the program IDs in both files match
- Example:
# In Anchor.toml [programs.localnet] rarible_editions = "587DoLBH2H39i5bToWBc6zRgbD2iJZtc4Kb8nYsskYTq" rarible_editions_controls = "5hEa5j38yNJRM9vQA44Q6gXVj4Db8y3mWxkDtQeofKKs"
// In constants.ts export const rarible_editions_PROGRAM_ID = new PublicKey("587DoLBH2H39i5bToWBc6zRgbD2iJZtc4Kb8nYsskYTq"); export const rarible_editions_CONTROLS_PROGRAM_ID = new PublicKey("5hEa5j38yNJRM9vQA44Q6gXVj4Db8y3mWxkDtQeofKKs");
- Open
-
Run tests:
- To build and run tests:
anchor test
- To skip building and only run tests (faster for repeated testing):
anchor test --skip-build
- To build and run tests:
-
If you encounter wallet-related errors, ensure your
Anchor.toml
is configured to use your local keypair:[provider] cluster = "localnet" wallet = "~/.config/solana/id.json"
-
For any issues or questions, please open an issue in the GitHub repository.
We welcome contributions! Please see our CONTRIBUTING.md file for details on how to contribute to this project.