Skip to content

Commit

Permalink
Merge pull request #46 from reeshavacharya/main
Browse files Browse the repository at this point in the history
Add use stories for staking and Plutus tests
  • Loading branch information
CarlosLopezDeLara authored Jun 18, 2024
2 parents b89353a + 11bb57e commit 9440e5e
Show file tree
Hide file tree
Showing 6 changed files with 73 additions and 0 deletions.
14 changes: 14 additions & 0 deletions docs/inventory/09-staking.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
sidebar_label: Staking user stories
title: Staking user stories
sidebar_position: 9
slug: /staking
---

| User Story Id | Title | User Story | Acceptance Criteria |
| ------------- | ----- | ---------- | ------------------- |
| **STK-001** | Multiple Stake Address Registration | As a Dapp developer, <br>I want to register multiple stake addresses in a single transaction | **Given That** I am using cardano-api or cardano-cli<br>**When** I need to register multiple stake addresses in a single transaction<br>**Then** the transaction should be successfully submitted. |
| **STK-002** | Multiple Stake Pool Registration | As a Dapp developer, <br>I want to register multiple stake pools in a single transaction | **Given that** I am using cardano-api or cardano-cli<br>**When** I need to register multiple stake pools in a single transaction<br>**Then** the transaction should be successfully submitted. |
| **STK-003** | Multiple Stake Address Delegation | As a Dapp developer, <br>I want to delegate multiple stake addresses to various stake pools in a single transaction | **Given that** I am using cardano-api or cardano-cli<br>**When** I need to delegate multiple stake addresses to various stake pools in a single transaction<br>**Then** the transaction should be successfully submitted. |
| **STK-004** | Multiple Stake Address Deregistration | As a Dapp developer, <br>I want to deregister multiple stake addresses in a single transaction | **Given that** I am using cardano-api or cardano-cli<br>**When** I need to deregister multiple stake addresses in a single transaction<br>**Then** the transaction should be successfully submitted. |
| **STK-005** | Multiple Stake Pool Retirement | As a Dapp developer, <br>I want to retire multiple stake pools in a single transaction | **Given that** I am using cardano-api or cardano-cli<br>**When** I need to retire multiple stake pools in a single transaction<br>**Then** the transaction should be successfully submitted. |
16 changes: 16 additions & 0 deletions docs/inventory/plutus/08-plutus-v3.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
sidebar_label: PlutusV3 user stories
title: PlutusV3 user stories
sidebar_position: 8
slug: /plutus-v3
---

| User Story Id | Title | User Story | Acceptance Criteria |
| ------------- | ----- | ---------- | ------------------- |
| **PLT-001** | Implement `BLS12_G2` Functions | As a Dapp developer,<br>I want to implement `BLS12_G2` functions in a PlutusV3 smart contract | **Given that** I am a Dapp developer<br>**When** I implement `BLS12_G2` functions in a PlutusV3 smart contract<br>**Then** the functions should work correctly within the contract. |
| **PLT-002** | Implement `BLS12_G1` Functions | As a Dapp developer,<br>I want to implement `BLS12_G1` functions in a PlutusV3 smart contract | **Given that** I am a Dapp developer<br>**When** I implement `BLS12_G1` functions in a PlutusV3 smart contract<br>**Then** the functions should work correctly within the contract. |
| **PLT-003** | Implement `verifySchnorrSecp256k1Signature` | As a Dapp developer,<br>I want to implement the `verifySchnorrSecp256k1Signature` function in a PlutusV3 smart contract for Schnorr signature verification | **Given that** I am a Dapp developer<br>**When** I implement the `verifySchnorrSecp256k1Signature` function in a PlutusV3 smart contract<br>**Then** Schnorr signature verification should be performed correctly. |
| **PLT-004** | Implement `keccak_256` for ECDSA | As a Dapp developer,<br>I want to implement the `keccak_256` function in a PlutusV3 smart contract to validate ECDSA signatures formatted via the EVM standard | **Given that** I am a Dapp developer<br>**When** I implement the `keccak_256` function in a PlutusV3 smart contract<br>**Then** ECDSA signatures formatted via the EVM standard should be validated correctly. |
| **PLT-005** | Implement `verifyEcdsaSecp256k1Signature` | As a Dapp developer,<br>I want to implement the `verifyEcdsaSecp256k1Signature` function in a PlutusV3 smart contract for ECDSA signature verification | **Given that** I am a Dapp developer<br>**When** I implement the `verifyEcdsaSecp256k1Signature` function in a PlutusV3 smart contract<br>**Then** ECDSA signature verification should be performed correctly. |
| **PLT-006** | Implement `verifyEd25519Signature` | As a Dapp developer,<br>I want to implement the `verifyEd25519Signature` function in a PlutusV3 smart contract for Ed25519 signature verification | **Given that** I am a Dapp developer<br>**When** I implement the `verifyEd25519Signature` function in a PlutusV3 smart contract<br>**Then** Ed25519 signature verification should be performed correctly. |
| **PLT-007** | Implement `blake2b_224` for PubKeyHash | As a Dapp developer,<br>I want to implement the `blake2b_224` function in a PlutusV3 smart contract for validating pubKeyHash on-chain | **Given that** I am a Dapp developer<br>**When** I implement the `blake2b_224` function in a PlutusV3 smart contract<br>**Then** pubKeyHash validation should be performed correctly on-chain. |
12 changes: 12 additions & 0 deletions docs/inventory/plutus/10-spending.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
sidebar_label: Spending user stories
title: Spending user stories
sidebar_position: 10
slug: /spending
---

| User Story Id | Title | User Story | Acceptance Criteria |
| ------------- | ----- | ---------- | ------------------- |
| **SPEND-001** | Lock and Redeem Ada in Same Script | As a Dapp developer,<br>I want to lock some Ada in a PlutusV3 script and redeem some Ada from the same script in the same transaction | **Given that** I am a Dapp developer<br>**When** I lock some Ada in a PlutusV3 script and redeem some Ada from the same script in a single transaction<br>**Then** the transaction should be successfully submitted as long as there is no violation in the script logic. |
| **SPEND-002** | Lock and Redeem Ada in Different Scripts | As a Dapp developer,<br>I want to lock some Ada in a PlutusV3 script and redeem some Ada from a different script in the same transaction | **Given that** I am a Dapp developer<br>**When** I lock some Ada in a PlutusV3 script and redeem some Ada from a different script in a single transaction<br>**Then** the transaction should be successfully submitted as long as there is no violation in the script logic. |
| **SPEND-003** | Redeem Ada with Multiple Signatures | As a Dapp developer,<br>I want to redeem some Ada from a PlutusV3 script that requires multiple signatures | **Given that** I am a Dapp developer<br>**When** I redeem some Ada from a PlutusV3 script that requires multiple signatures (by using multiple signatures in the transaction’s witness set)<br>**Then** the transaction should be successfully submitted as long as there is no violation in the script logic. |
10 changes: 10 additions & 0 deletions docs/inventory/plutus/11-minting.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
sidebar_label: Minting user stories
title: Minting user stories
sidebar_position: 11
slug: /minting
---

| User Story Id | Title | User Story | Acceptance Criteria |
| ------------- | ----- | ---------- | ------------------- |
| **MINT-001** | Mint Tokens with Maximum Execution Units | As a Dapp developer,<br>I want to mint tokens with maximum execution units | **Given that** I am a Dapp developer<br>**When** I mint tokens with exactly maximum execution units<br>**Then** the transaction should utilize the maximum execution units and mint the tokens as expected. |
10 changes: 10 additions & 0 deletions docs/inventory/plutus/12-reference-input.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
sidebar_label: Reference Input user stories
title: Reference Input user stories
sidebar_position: 12
slug: /reference-input
---

| User Story Id | Title | User Story | Acceptance Criteria |
| ------------- | ----- | ---------- | ------------------- |
| **REFIN-001** | Reference Input Visibility | As a Dapp developer,<br>I want visibility over the reference input's address, datum, and value on-chain | **Given that** I am a Dapp developer<br>**When** I need visibility of the reference input's address, datum, and value on-chain<br>**Then** this information should be accessible to me through related plutus functions on-chain. |
11 changes: 11 additions & 0 deletions docs/inventory/plutus/13-script-efficiency.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
sidebar_label: Script Efficiency user stories
title: Script Efficiency user stories
sidebar_position: 13
slug: /script-efficiency
---


| User Story Id | Title | User Story | Acceptance Criteria |
| ------------- | ----- | ---------- | ------------------- |
| **EFF-001** | Shorter PlutusV3 Script with `plcVersion110` | As a Dapp developer,<br>I want to ensure that my smart contract written in PlutusV3 and compiled using `plcVersion110` generates a shorter script than my smart contract written in PlutusV2 and compiled using `plcVersion100` | **Given that** I am a Dapp developer<br>**When** I write a smart contract in PlutusV3 and compile it using `plcVersion110`<br>**Then** the resulting script should be shorter than the equivalent PlutusV2 smart contract compiled using `plcVersion100`. |

0 comments on commit 9440e5e

Please # to comment.