NT-NFT Pallet
January 13, 2023 ยท View on GitHub
Attribution
The NT-NFT pallet's approach to interacting with NFT collections and items is inspired by Parity's Uniques Pallet Which is licensed under Apache-2.0.
NT-NFT Pallet Setup and Testing Guide (Ubuntu)
Prerequisite Setup
Install Dependencies
sudo apt install build-essential
sudo apt install -y git clang curl libssl-dev llvm libudev-dev
Install Rust
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
source ~/.cargo/env
rustup default stable
rustup update stable
rustup update nightly
rustup install nightly-2022-09-19
rustup override set nightly-2022-09-19
rustup target add wasm32-unknown-unknown
rustup target add wasm32-unknown-unknown --toolchain nightly
Deploy a Local Ventur Node
Fetch the code
The following command pulls the ventur-node code from our github repo:
git clone https://github.com/PopularCoding/ventur
cd ventur
Run the node
The following command builds the node. (This may take some time):
cargo run --release -- --dev
Run Unit Tests
Unit tests can be run locally using the following command:
cargo test
Manual Test Guide
1. Start the node
cargo run --release -- --dev
| Running your local node |
|---|
![]() |
2. Access the Node through the polkadot.js.org interface
Once you have a ventur node running locally, follow this link: https://polkadot.js.org/apps/?rpc=ws://127.0.0.1:9944#/explorer
| Accessing your Development Node Endpoint in polkadot.js.org |
|---|
![]() |
Confirm that you can see the recent blocks listed. If you are not able to access the block explorer on polkadot.js.org, you should:
-
Confirm that your Ventur node is running
-
Check if your Ventur node is running the JSON-RPC WS server on an address and port other than
127.0.0.1:9944a. If your node is running on a different address and port, update the custom endpoint in polkadot.js.org to the address and port number your node is servingSetting your Development Node Endpoint in polkadot.js.org 
3. Test Creating an NT-NFT Collection
| 1. Create an NT-NFT Collection |
|---|
![]() |
| Create an NT-NFT Collection. |
| Example values: |
collectionId: 150 |
imageIpfsCid: QmaG1CtUr74GPQwZeAnFhpiSgwtwGyR3zK2BRYh4DPDw3c |
metadataIpfsCid: Qmb232AquR57EMUGgU92TxeZ8QyAJF5nERjdPZRNNJoh6z |
| 2. Verify created NT-NFT Collection in Chain State |
|---|
![]() |
4. Test Minting an NT-NFT
| 1. Mint an NT-NFT to the previously created Collection |
|---|
![]() |
| 2. Verify minting NT-NFT to Collection in chain state |
|---|
![]() |
5. Test Burning an NT-NFT
| 1. Burn the previously created NT-NFT |
|---|
![]() |
| 2. Verify burning the NT-NFT in chain state |
|---|
![]() |
6. Test Assigning an NT-NFT to an Address
| 1. Mint another NT-NFT to the previously created Collection |
|---|
![]() |
| 2. Assign the new NT-NFT to an Account |
|---|
![]() |
| 3. Verify the NT-NFT Proposed Assignment in chain state |
|---|
![]() |
7. Test Accepting an Assigned NT-NFT
| 1. Accept the NT-NFT assignment from the assigned account |
|---|
![]() |
| 2. Verify the Accepted NT-NFT in chain state |
|---|
![]() |
8. Test Rejecting an Assigned NT-NFT
| 1. Mint another NT-NFT to the previously created Collection |
|---|
![]() |
| 2. Assign the new NT-NFT to an Account |
|---|
![]() |
| 3. Verify the NT-NFT Proposed Assignment in Chain State |
|---|
![]() |
| 3. Reject NT-NFT Proposed Assignment |
|---|
![]() |
| 3. Verify the NT-NFT Rejection in Chain State |
|---|
![]() |
![]() |
9. Test Discarding an Assigned NT-NFT
| 1. Mint another NT-NFT to the previously created Collection |
|---|
![]() |
| 2. Assign the new NT-NFT to an Account |
|---|
![]() |
| 3. Accept the new NT-NFT from the Account |
|---|
![]() |
| 2. Verify the Accepted NT-NFT in chain state |
|---|
![]() |
| 2. Discard the NT-NFT |
|---|
![]() |
| 2. Verify Discarding the NT-NFT in chain state |
|---|
![]() |
10. Test Freezing an NT-NFT Collection
| 1. Freeze the previously created Collection |
|---|
![]() |
| 2. Attempt to mint another NT-NFT to the Collection |
|---|
![]() |
| 2. Verify in chain state that the mint failed |
|---|
![]() |
11. Test Thawing an NT-NFT Collection
| 1. Thaw the frozen Collection |
|---|
![]() |
| 2. Attempt to mint another NT-NFT to the Collection |
|---|
![]() |
| 2. Verify in chain state that the mint succeeded |
|---|
![]() |






























