Skip to content

Commit

Permalink
Merge pull request metaplex-foundation#761 from aheckmann/document_ma…
Browse files Browse the repository at this point in the history
…nual_testing_steps

Add test instructions to readme
  • Loading branch information
adamjeffries authored Oct 19, 2021
2 parents 0927e3e + ef85d94 commit 999fdf5
Showing 1 changed file with 59 additions and 5 deletions.
64 changes: 59 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,8 @@ Clone the repo, and run `yarn start` to deploy.

```bash
$ git clone https://github.com/metaplex-foundation/metaplex.git
$ cd metaplex
$ cd js
$ yarn install
$ yarn bootstrap
$ yarn build
$ cd metaplex/js
$ yarn install && yarn bootstrap && yarn build
$ yarn start
```

Expand Down Expand Up @@ -128,3 +125,60 @@ Tag each collaborator, set custom percentages, and you’re off to the races. Ea
Metaplex's off-chain component allows creators to launch a custom storefront, similar to Shopify or WordPress. This open-source project provides a graphical interface to the on-chain Metaplex program, for creators, buyers, and curators of NFTs. The design and layout of storefronts can be customized to suit the needs of the entity creating it, either as a permanent storefront or an auction hub for a specific auction or collection.

All identification on the Storefront is based on wallet addresses. Creators and store admins sign through their wallets, and users place bids from connected wallets. Custom storefronts allow creators to create unique experiences per auction. Additionally, the Metaplex Foundation is working on multiple partnerships that will enable building immersive storefronts using VR/AR.

## Development

### Testing

Testing changes to a rust program

```
# Change to devnet
solana config set --url devnet
# Build the project (takes a few mins)
cd rust
cargo build-bpf
# While you wait for the previous step to complete, find the current program id
# of the program you plan to test by searching the code base. Save this for
# later.
# After the build step completes, deploy the program to devnet
solana program deploy ./path/to/the_program.so -u devnet
# NOTE: If you receive an error stating insufficient funds, recoup the funds
# used during the failed deployment. You may also see the following error which
# also means insufficient funds:
# "Error: Deploying program failed: Error processing Instruction 1: custom program error: 0x1"
solana program close --buffers
# NOTE: If you had insufficient funds, airdrop yourself some SOL, then run the deploy
# command again. I needed roughly 5 SOL to deploy the auction contract.
solana airdrop 5
# After successful deploy, a new Program Id will be printed to your terminal. Copy this
# and update the program's id everywhere in the code base. This way, during testing, we
# always call the version of the program we are testing instead of the stable one.
# DO NOT SKIP THIS STEP or you won't test your changes
# Next, comment out your js/packages/web/.env variables to force creation of a fresh new store
# Now start up the UI
cd ../js/packages
yarn && yarn bootstrap
yarn start
# Open the site in a browser in *incognito* mode http://localhost:3000
# In the incognito browser, create a new wallet by visiting https://sollet.io
# Copy the wallet address
# You'll need SOL added to the new wallet
solana airdrop 4 NEW_WALLET_ADDRESS
# Now visit the site (in incognito mode)
# Connect your new wallet
# Create a new store
# Test your program changes
```

0 comments on commit 999fdf5

Please sign in to comment.