Skip to content

vnavascues/auction-platform

Repository files navigation

CC BY-SA 4.0 Known Vulnerabilities Actions Status codecov Maintainability

Auction Platform - Backend

Introduction

This DApp is based on the Auction Dapp presented in the Chapter 12 of the Mastering Ethereum by Andreas M. Antonopoulos, Gavin Wood book.

The summary quote from the book:

The Auction DApp allows a user to register a "deed" token, which represents some unique asset, such as a house, a car, a trademark, etc. Once a token has been registered, the ownership of the token is transferred to the Auction DApp, allowing it to be listed for sale. The Auction DApp lists each of the registered tokens, allowing other users to place bids. During each auction, users can join a chat room created specifically for that auction. Once an auction is finalized, the deed token ownership is transferred to the winner of the auction.

Contents

Build

BEWARE: git ignored.

A set of builds grouped as follows:

  • artifacts/: contracts JSON artifacts generated by Buidler.

  • typechain/: contracts TypeScript types generated by TypeChain.

Contracts

  • AuctionRepository.sol: the contract that manages the "deeds" auctions, e.g. create/cancel/end an auction, bid an auction. It is an

  • DeedRepository.sol: the contract that manages the creation of a "deed" (an ERC721 non-fungible token).

Coverage

BEWARE: git ignored.

Unit tests coverage report generated by solidity-coverage.

Scripts

TODO

Tasks

Scripts (tasks) that extend the default Buidler ones (e.g. typechain, clean). Use npx buidler command for listing all the available tasks.

Tests

A set of Waffle tests grouped as follows:

  • integration/: TODO (but expected to contain some user cases).

  • unit/: contracts unit tests.

Types

A set of TypeScript types used by buidler.config.ts.

BEWARE: once buidler-typechain plugin supports ethers-v5, the TypechainConfig interface will be removed.

Requirements

1. NPM Dependencies

$ npm install

NPM Scripts

Build

Command Description
build compile + typechain commands
build:clean build + clean commands
clean Default Buidler clean, delete current compilation
compile Default Buidler compile, compile the contracts
typechain Generate contracts TypeScript types

Coverage

Command Description
coverage Generate a coverage report for the unit tests suite

Lint

Command Description
lint:check Default Buidler check
lint:sol Check Solidity files (contracts)
lint:ts Check TypeScript files (e.g. tasks, tests)

Prettier

Command Description
prettier Check .js, .json, .md, .sol and .ts files
prettier:sol Check Solidity files (contracts)
prettier:ts Check TypeScript files (e.g. tasks, tests)

Test

Command Description
test Default Buidler test execution
test:unit Run unit tests suite

IDE Plugins & Extensions

Visual Studio Code

Better Comments

ESLint

Mocha Test Explorer

MythX

Prettier - Code formatter

Solidity

Solidity Visual Developer

License

This repository is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

CC BY-SA 4.0

About

A DApp for auctioning deeds (backend)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published