This repository contains the source code for my blog post Using PDAs and SPL Token in Anchor. The code contains the following:
- Solana program code to initialize a new payment, complete a payment, pull back a payment
- Unit tests for golden path scenarios
Nothing aside from teaching people how to program with Anchor. This program is not too useful and, most importantly, this program is not audited 😀.
- Install Anchor 0.18 here
- Install Node v17.0.1 or greater (we are using v17.0.1 here as reference)
- run
npm intall
to ensure dependencies are met - run
anchor test
and all tests should run successfully!
Feel free to reach out to me at @pirosb3 on Twitter! or simply open a PR 😀 - Thank You!