Skip to content

Main smart contracts for Kyber Network, including the main platform contract, reserve contracts etc.

License

Notifications You must be signed in to change notification settings

KyberNetwork/smart-contracts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

3dc0bae · May 29, 2020
May 29, 2020
Dec 3, 2019
May 29, 2020
Mar 29, 2018
Jul 26, 2017
Mar 2, 2020
Mar 18, 2018
May 29, 2020
May 29, 2020
Feb 7, 2018
Jan 31, 2019
Jan 31, 2019
Jun 28, 2018
May 29, 2020
May 29, 2020
Apr 17, 2020
May 29, 2020
May 29, 2020
May 29, 2020
May 29, 2020
Feb 7, 2018
Jul 2, 2017
May 29, 2020
May 29, 2020
May 29, 2020
May 29, 2020
May 29, 2020
May 29, 2020
May 29, 2020
May 29, 2020
May 29, 2020
May 29, 2020
May 29, 2020
Apr 23, 2018
May 29, 2020
May 29, 2020
May 29, 2020
May 29, 2020
Mar 3, 2020
May 29, 2020
Jan 25, 2018

Repository files navigation

Introduction

This repository contains kyber network smart contracts. For more details, please visit our developer portal

API

Public facing interfaces for kyber network (folder: contracts/sol6):

  1. IKyberNetworkProxy.sol - Get rate and trade APIs. Hint handler address.
  2. ISimpleKyberProxy.sol - Simple trade functions.
  3. IKyberHintHandler.sol - Build hints for advanced trade functionality.
  4. IkyberDAO - Interact with Kyber dao.
  5. Dao/IKyberStaking - interact with staking contract.

Setup

  1. Clone this repo
  2. npm ci

Compilation with Buidler

  1. ./cmp.sh to compile contracts for all solidity verseions.
  2. ./cmpSol6.sh to compile only sol6 contracts

Testing with Buidler

  1. If contracts have not been compiled, run ./compilation.sh. This step can be skipped subsequently.
  2. Run ./tst.sh
  3. Use -f for running a specific test file.
  4. Use -a to run tests for all solidity versions. Runs only sol6 tests by default.

Example Commands

./tst.sh (Run only sol6 tests) ./tst.sh -f ./test/sol4/kyberReserve.js (Test only kyberReserve.js) ./tst.sh -a (Run sol4, sol5, sol6 tests)

Example

npx buidler test --no-compile ./test/sol6/kyberNetwork.js

Coverage with buidler-coverage

  1. Run ./coverage.sh
  2. Use -f for running a specific test file.

Example Commands

./coverage.sh -f ./test/sol6/kyberNetwork.js (Coverage for only kyberNetwork.js)

About

Main smart contracts for Kyber Network, including the main platform contract, reserve contracts etc.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published