Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Truffle Quick Start Guide

You're reading from   Truffle Quick Start Guide Learn the fundamentals of Ethereum development

Arrow left icon
Product type Paperback
Published in Jun 2018
Publisher Packt
ISBN-13 9781789132540
Length 170 pages
Edition 1st Edition
Languages
Concepts
Arrow right icon
Author (1):
Arrow left icon
Nikhil Bhaskar Nikhil Bhaskar
Author Profile Icon Nikhil Bhaskar
Nikhil Bhaskar
Arrow right icon
View More author details
Toc

Writing unit tests with Solidity

Before we start the exercises in this chapter, let's do the usual housekeeping:

  • Inside your truffle-practice folder, create a new folder called chapter6

Great! That's it. Let's get started with this chapter. Now, we've already built a few mini applications, so which one should we write tests for? Let's write tests for the mini-application we wrote in Chapter 1, Truffle for Decentralized Applications. Why? There are two reasons:

  • The Chapter 1, Truffle for Decentralized Applications, project contains fundamental Solidity elements that we should write tests for.
  • The Chapter 1, Truffle for Decentralized Applications, project does not rely on a particular JavaScript framework. Since it's in VanillaJS, you can just focus on writing unit tests without worrying about framework-specific caveats.

Since we are writing tests...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image