John Hughes, Profesor, Chalmers University of Technology, Göteborg, Sweden
The Cardano blockchain underlies one of the world’s top-ten cryptocurrencies, and supports smart contracts written in Haskell, which work very differently from those on the Ethereum Virtual Machine (the largest smart contract platform). While some vulnerabilities are fixed as a result, it is still possible in principle for large sums to be stolen, or simply lost, due to bugs in smart contracts. Testing smart contracts thoroughly is thus of paramount importance.
QuickCheck is a ‘property-based testing’ tool, that generates random test cases and validates observed system behaviour against a kind of formal specification. But what should a formal specification of a smart contract look like? Quviq has been developing a QuickCheck-based test framework for these smart contracts. I’ll talk about the framework itself, and some of the challenges we have addressed, and which remain to be addressed.