Skip to content

AleksandrinaAleksieva/testing-store

Repository files navigation

QA Task - Testing Ethereum

Overview

Create a test based on Hardhat for testing contract deployment and interaction.

Learning Materials

🧯 01. Intro to Blockchain for FE developers

🎮 02. Intro to Ethereum

🧯 03. Hardhat general overview

🧥 (Optional) 04. Solidity - all you need to know about it

Task Definition

Create a Hardhat project:

  1. Add the Store Contract in the repo. The contract abides to the following specification:
  • The administrator (owner) of the store should be able to add new products and the quantity of them.
  • The administrator should not be able to add the same product twice, just quantity.
  • Buyers (clients) should be able to see the available products and buy them by their id.
  • Buyers should be able to return products if they are not satisfied (within a certain period in blocktime: 100 blocks).
  • A client cannot buy the same product more than one time.
  • The clients should not be able to buy a product more times than the quantity in the store unless a product is returned or added by the administrator (owner)
  1. Create a test suite in hardhat. The suite should provide extensive coverage for the Store Contract.
  2. [Optional] Setup a GitHub repo with CI. The CI should be able to: Compile the contract Deploy the contract on a local hardhat node Execute the suite against a local node and verify that it gets full code coverage

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published