# Better Smart Contracts with Behavior-Driven Development with Thomas Vieira and Neodaoist

- Channel: [Ethereum Denver](https://streameth.org/ethereum-denver)
- Date: 2023-10-07
- Duration: 29:07
- Topics: Entertainment
- Watch: https://streameth.org/watch/yt-T70txXsSxig
- YouTube: https://www.youtube.com/watch?v=T70txXsSxig

## Description

Behavior-Driven Development (BDD) is a method which puts user needs and team conversations at the heart of the software dev process. While BDD helps web2 teams write more valuable, secure code, it has not become popular for smart contract development yet. We aim to change that by sharing our experience successfully using BDD to write more secure DeFi smart contracts.

In this talk, Pete Laird (or Bufficorn Ventures and my teammate on ETH Denver 2022 finalist team LOUDVERSE) and I will walk participants through writing more secure and usable Solidity smart contracts using BDD. We first explain the what and why of BDD, then we describe how BDD works, and finally we code an ERC4626 vault using BDD together.

Workshop Outline

- BDD — The What and Why
- Modern DeFi development and the challenges of one-way, immutable deploys
- How BDD helps deliver more valuable, secure, usable software
- Test-Driven Development, and beyond, with Foundry/Forge/Ethers-RS/Ethers-JS
- The Mechanics of BDD
- Cucumber as your protocol's executable specification
- Features, Scenarios, and Step Definitions
- Web3 specifics — forking mainnet, contract objects, test doubles
- A Real-Life Example
- Writing an ERC4626 from scratch using BDD
- How to try out BDD on your next contract
- Where to from here, Q&A

https://twitter.com/neodaoist

Thomas Vieira
Protocol Engineer, Product Manager
main project — Valorem, friend of — Juicebox DAO, DAObi, Water&Music DAO, 1729
Neodaoist is a protocol engineer and product manager. He leads product management, as well as writing Solidity smart contracts, and acting as our resident test-driven development evangelist. Before getting involved in blockchain and DeFi, he headed up engineering and product organizations at mobile, ad-tech, and enterprise SaaS startups, with one successful exit so far.
