Buidler plugin for integration with TruffleContract from Truffle 4
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
scripts
src
test
.env
.gitignore
.travis.yml
LICENSE
README.md
package.json
tsconfig.json
tslint.json
yarn.lock

README.md

npm Build Status

buidler-truffle4

Buidler plugin for integration with TruffleContract from Truffle 4

What

This plugin brings to Buidler TruffleContracts from Truffle 4. With it you can call contract() and artifacts.require() like you normally would with Truffle. Interact with your contracts with a familiar API from tasks, scripts and tests.

Additionally, you can migrate your contracts to Solidity 5 without needing to migrate your tests to Truffle 5.

Installation

npm install @nomiclabs/buidler-truffle4 web3@^0.20.7

And add the following require to the top of your buidler.config.js:

require("@nomiclabs/buidler-truffle4");

Tasks

This plugin creates no additional tasks.

Environment extensions

An instance of TruffleEnvironmentArtifacts is injected into env.artifacts and the method contract() is injected into the global scope for using in tests.

Usage

There are no additional steps you need to take for this plugin to work. Install it, run npx buidler test and your Truffle tests should run with no need to make any modifications.