This presentation was recorded at YOW! 2017. #GOTOcon #YOW https://yowcon.com Jacob Stanley - Senior Software Engineer at Lighthouse Financial Technologies RESOURCES https://twitter.com/jacobstanley https://www.linkedin.com/in/jacobstanley https://github.com/jacobstanley https://hedgehog.qa ABSTRACT #QuickCheck is a shockingly effective tool for validating the initial and ongoing correctness of production software. One of QuickCheck’s most compelling features is that when a test failure is found, the failing test case is simplified to a minimal counterexample, through a process called shrinking. This makes it significantly easier to understand why a test has failed. The #Haskell version of QuickCheck, and most of its derivatives, tackle shrinking in a type-directed fashion. #Quiviq’s #Erlang version on the other hand, and a few similar tools for other dynamic languages, couple their shrinking capability directly with their test data generators. Now, types are good, right? So surely the Haskell version is better! Why wouldn’t we want to use types to guide our shrinking process? In this talk, I will highlight the technical and social problems that we, at Ambiata, experienced with type-directed shrinking. We’ll explore the alternative, integrated shrinking, and we’ll see that even in a statically typed language, integrated shrinking provides enormous benefits for developer productivity. We will see how to implement integrated shrinking, using rose trees, in the context of a strong statically typed language. Finally, we will see how to create a rose tree monad transformer, a tool which will allow us to create effectful test data generators, which still shrink properly! From this talk, the audience will learn about the difference between type-directed and integrated shrinking, and how integrated shrinking can provide superior counterexamples, while placing a smaller burden on developers writing tests. [...] RECOMMENDED BOOKS Rebecca Skinner • Effective Haskell • https://amzn.to/3SxTpwY Kevlin Henney • 97 Things Every Programmer Should Know • https://amzn.to/2Yahf9U Henney & Monson-Haefel • 97 Things Every Software Architect Should Know • https://amzn.to/3pZuHsQ Matthew Skelton & Manuel Pais • Team Topologies • http://amzn.to/3sVLyLQ Michael Jackson • Software Requirements and Specifications • https://amzn.to/3ql2T14 Geoffrey West • Scale • http://amzn.to/3eKMbpc Donald G. Reinertsen • The Principles of Product Development Flow • https://amzn.to/3hJ2Ye2 https://twitter.com/GOTOcon https://www.linkedin.com/company/goto- https://www.instagram.com/goto_con https://www.facebook.com/GOTOConferences #FunctionalProgramming #Programming #SoftwareEngineering #JacobStanley #YOWcon Looking for a unique learning experience? Attend the next GOTO conference near you! Get your ticket at https://gotopia.tech Sign up for updates and specials at https://gotopia.tech/newsletter SUBSCRIBE TO OUR CHANNEL - new videos posted almost daily. https://www.youtube.com/user/GotoConferences/?sub_confirmation=1
Get notified about new features and conference additions.