Property-based testing - let your testing library work for you

location_city Online schedule Mar 25th 05:00 - 05:45 PM IST place Zoom people 50 Interested

Don't ask what you can do for your testing library, ask what it can do for you! So what can it do? It turns out that much more than displaying a nice green and red report. What if we make the library generate the test data? And while we're at it, maybe it could also think of the edge cases for which our code is wrong? Oh, and when it finds them, it should simplify them a bit before returning to us, so that we can quickly identify the root cause of the problem. And repeat that a thousand times, just to be sure. Sounds good? That's exactly what property-based testing has to offer. I'll show how to get started with this kind of testing, using jqwik (https://jqwik.net/) as an example. But isn't it all too good to be true, surely there's some fine print? Of course there is. I'll cover that as well.

 
 

Outline/Structure of the Talk

https://slides.com/magdastozek/property-based-testing-858a93

Learning Outcome

Property-based testing as a new tool in the programmer's toolbox

Target Audience

Programming Community

Video


schedule Submitted 6 months ago

  • Richard Feldman
    keyboard_arrow_down

    Richard Feldman - The Essence of Functional Programming

    Richard Feldman
    Richard Feldman
    Head of Technology
    NoRedInk
    schedule 6 months ago
    Sold Out!
    45 Mins
    Keynote
    Beginner

    This talk dives into the origins of functional programming, going all the way back to where the term was first introduced, to see how it evolved over time into our modern understanding of what FP essentially involves.

  • Dean Wampler
    keyboard_arrow_down

    Dean Wampler - Lessons Learned from 15 Years of Scala in the Wild

    Dean Wampler
    Dean Wampler
    Director of Engineering
    IBM Research
    schedule 7 months ago
    Sold Out!
    45 Mins
    Keynote
    Advanced

    Scala 3 was introduced last year. It introduced significant changes to the language, many of which were motivated by the lessons learned from the past 15 or so years of actual use in many open-source and commercial applications.

    I'll explore these lessons and how Scala 3 addresses them. Many revolve around the pros and cons of implicits. Also, changes to the type system make it more "regular", robust, and expressive. Finally, the new, optional, and controversial "Python-like" syntax promotes even more brevity. It also acknowledges how influential and pervasive Python has become across our industry.

    But there are many practical areas where future work is required, many of which are larger than the scope of Scala itself. We still live in "dependency hell". We still use too many obsolete idioms that hide accidental complexity, rather than forcing us to fix it. What should we do about these issues? 

  • Bartosz Milewski
    keyboard_arrow_down

    Bartosz Milewski - Teaching Optics through Conspiracy Theories

    Bartosz Milewski
    Bartosz Milewski
    Math Evangelist
    Programming Cafe
    schedule 7 months ago
    Sold Out!
    45 Mins
    Keynote
    Advanced

    With polymorphic functions you can often tell how they are implemented by looking at their outputs. The more polymorphic the function, the more you can tell about its internal workings. Lenses, as well as more general optics, have convenient polymorphic implementations in terms of functors and profunctors. But under layers of abstractions they are hiding some simple truths. We are going to get to the bottom of this conspiracy.

  • Michael Snoyman
    Michael Snoyman
    VP, Engineering
    FP Complete
    schedule 6 months ago
    Sold Out!
    45 Mins
    Talk
    Intermediate

    Many of us in the functional programming community believe that FP is a significant improvement over object oriented programming, arguably the dominant programming paradigm today. That of course begs the question: how did an inferior paradigm grab so much mindshare and market share and rise to prominence? I'm going to tell the story a bit differently, exploring a different take on the strengths of OOP, and how that affects those of us who advocate for functional programming.

  • Nikhil Barthwal
    keyboard_arrow_down

    Nikhil Barthwal - Implementing Event-Driven Microservices architecture in Functional language

    Nikhil Barthwal
    Nikhil Barthwal
    Sr. Software Engineer
    Facebook
    schedule 6 months ago
    Sold Out!
    45 Mins
    Tutorial
    Intermediate

    Web services are typically stateless entities, that need to operate at scale at large. Functional paradigm can be used to model these web services work and offer several benefits like scalability, productivity, and correctness. This talk describes how to implement Event-Driven Microservices in functional programming languages with examples in F#.

    Immutability allows infinite scalability as it eliminates the need to worry about a mutex, a lock, or a race. As functional code is much more terse compared to object-oriented code, it provides productivity benefits. Its strict typing makes writing correct code easy as mismatches of types are caught at compile time.

    The objective of the talk is to show how to create a scalable & highly distributed web service in F#, and demonstrate how various characteristics of functional paradigm captures the behavior of such services architecture very naturally.

  • 20 Mins
    Talk
    Beginner

    Some people even say names don't matter. While it is widely held that good naming is one of the most important aspects of programming, is there such a thing as an objectively good name?

    As part of a discussion of the philosophy of programming, we'll look at what are the real aims of naming things well, and what considerations we should have in mind when discussing them. We'll have a look at alternatives and what they bring that names do not.

  • Mey Beisaron
    keyboard_arrow_down

    Mey Beisaron - Multiplayer Online Game in Clojure: Attack of the Clones

    45 Mins
    Demonstration
    Beginner

    When I say "Multiplayer online game development in Clojure" 2 questions probably pop right up : WHY? HOW?
    Why? because you can do it in under 100 lines of code, and it is pure FUN.
    How? Well that's exactly what we'll talk about in this session.
    I will present a simple MOG written in Clojure and go through each line of code - so you'll understand how you can do that yourself, even if you've never written a single line of Clojure before.
    Whether you’re a real Clojurian at heart or just interested in hearing a talk about Clojure from a sworn star wars fan - this talk is for you :)

  • Ben Evans
    keyboard_arrow_down

    Ben Evans - Do We Really Do FP in Java?

    Ben Evans
    Ben Evans
    Senior Principal Engineer
    Red Hat
    schedule 7 months ago
    Sold Out!
    45 Mins
    Talk
    Beginner

    Many Java developers believe that FP arrived in Java 8, with the addition of first-class lambda expressions and the Streams API. But is this really true? In this talk, Ben Evans will talk about what FP really is, examine whether Java can really be said to be FP or not - and consider whether things have improved with more recent versions, as well as some possibilities of how we could have done things differently (in another world).

  • Dhananjay Nene
    keyboard_arrow_down

    Dhananjay Nene - Snippets from an algorithmic trading system in Kotlin

    45 Mins
    Talk
    Intermediate

    This talk will introduce the audience to algorithmic trading, the design of an algorithmic trading system, and various snippets written in Kotlin that fulfil specific tasks that collectively contribute towards a full trading system. The rough sketch will be as follows

  • Debasish Ghosh
    keyboard_arrow_down

    Debasish Ghosh - Functional Programming patterns for designing modular abstractions

    Debasish Ghosh
    Debasish Ghosh
    Principal Software Engineer
    LeadIQ
    schedule 7 months ago
    Sold Out!
    45 Mins
    Talk
    Intermediate

    The biggest power of functional programming comes from the ability to treat functions as first class objects and the power to compose them incrementally to evolve larger functions out of smaller ones. Designing such functions as referentially transparent enables us to treat functions in programming just like functions in mathematics - side-effects are carefully abstracted through “effects” and delayed till the algebra of our program gets submitted to the run time system.

     

    In this talk I will discuss a few idioms and patterns on how using the power of composition can lead to development of modular abstractions. Instead of committing to an implementation prematurely we can define abstractions that focus on “what” it does deferring the “how” part to later stages of the lifecycle. In functional programming terminology we call the “what” part the algebra of our abstraction, and the “how” part the interpreter. Decoupling the two is one of the basic recommendations in functional programming. 

     

    I will use Haskell and Scala for the examples. I will discuss common functionalities that we use everyday in programming our domain models like validations, database interactions, managing exceptions, talking to external services etc. and show how to use the power of typed functional programming to make them more compositional.

  • Gopal S Akshintala
    keyboard_arrow_down

    Gopal S Akshintala - Fight Complexity with Functional Programming

    45 Mins
    Demonstration
    Intermediate

    A Metric-driven approach to reduce Cognitive Complexity in a code base, using Functional Programming, demoed **hands-on**, by solving a complex real-world ubiquitous design challenge - REST API Bulk Request Validation, with an extensible Framework that separates what-to-do (Validations) from how-to-do (Validation Orchestration). Let's do a case study of a successful implementation done by our team in the world's largest SaaS org, _Salesforce_, through our in-house baked FOSS library **Vader**.

  • Siddharth Kulkarni
    keyboard_arrow_down

    Siddharth Kulkarni - Fundamentals of Functional Programming

    Siddharth Kulkarni
    Siddharth Kulkarni
    Software Developer
    ThoughtWorks
    schedule 11 months ago
    Sold Out!
    45 Mins
    Talk
    Beginner

     

    You must have heard people talk about Functional programming whilst you nod apprehensively, and how cool people do functional programming. You must have heard people talk about functional purity and imperative blasphemy. But what exactly does functional programming entail? Why is it making a comeback? This talk is aimed at providing an objective and practical view of what FP can and cannot do, and how it's nothing to be scared of, what languages support functional style and how it can help alleviate some common programming problems.
     
     
  • Akshay Kumar Arumugasamy
    keyboard_arrow_down

    Akshay Kumar Arumugasamy / Christopher Anand - Teaching Functional Programming to Children

    20 Mins
    Talk
    Beginner

    Is functional programming for experts? We have found that children learning programming also benefit!

    Over the last 5 years, we have taught 25K children through the McMaster University’s outreach program McMaster Start Coding (Canada), and started training undergraduates from peer institutions, including Vellore Institute of Technology, Cihan University (Kurdistan), and Narasu’s Sarathy Institute of Technology (India), so that they they can create their own programs.

    Our main motivation for teaching functional programming to children is the similarity between algebra and functional programming. Algebra is a barrier to secondary and postsecondary education, and helping children overcome this barrier can have a huge impact.

    We continued to develop our program because both children and teachers loved it. Children find it easy to learn about functions when the functions draw shapes on their screen using a compositional language they find easy to learn. Teachers love it, because children immediately understand concepts including Cartesian coordinates which are difficult to motivate for some.

    In this talk we will explain the design philosophy behind our open-source graphics library GraphicSVG for Elm, and why we think Elm (with pure functions, and well-typed standard library) is the best language to teach 10- to 14-year olds.

    We will give you a toolkit for advocating functional programming in your local schools, and show what children can create, including children from Vikas School in Hyderabad who were isolating at home with only a smartphone to learn programming on.

  • Phillip Carter
    keyboard_arrow_down

    Phillip Carter - 5 years of trying to get people to use an FP language

    Phillip Carter
    Phillip Carter
    Senior Product Manager
    Honeycomb
    schedule 6 months ago
    Sold Out!
    45 Mins
    Case Study
    Beginner

    At Microsoft, Phillip worked on the F# language and tools from 2016 to 2021. In this talk, Phillip will recount the various strategies he and his team used to try and increase adoption of F#, and by extension, FP as a whole. Over this period of time, the F# language evolved and grew its user base substantially.

    Lots of experiments to increase adoption were tried, such as pivoting to data science, and most failed ... but some succeeded, hinting at some paths to adoption for FP that don't just involve a more mainstream language appropriating FP features. If you're interested in storytelling, learning about fun ways things failed, and curious about some things that succeeded in increasing adoption, check out this talk!

  • Alexander Granin
    keyboard_arrow_down

    Alexander Granin - Type-Level Domain-Specific Languages

    Alexander Granin
    Alexander Granin
    Haskell Consultant
    IE Granin A.S.
    schedule 10 months ago
    Sold Out!
    45 Mins
    Talk
    Advanced

    Haskell is known for its cutting-edge type system. All the major developments of the language are related to types today: Linear Types, Dependent Types, deep type-level features for enhancing ADTs. The language has taken the path of a trendsetter in this field, and many other languages derive their ideas bit by bit.

    What else Haskell is known for is the lack of understanding of how to use these complicated features in practice. What real tasks the type-level Haskell solves better than usual approaches. How to apply this rich world to day-to-day work. And what are the drawbacks of this type-level fanciness?

    My talk continues developing the methodology of pragmatic Haskell that I call Functional Declarative Design as I first introduced it in my book Functional Design and Architecture. I’ll present a couple of ways to build useful type-level eDSLs and will show the use cases of many important type features of the language. This is not just my voluntary exploration of the depths of Haskell, but rather a practical material one can take and solve own problems with the full understanding of the consequences. This will be a part of the material I’m preparing for my second book, Pragmatic Type-Level Design. 

  • Arun Madhavan Govindarajan
    keyboard_arrow_down

    Arun Madhavan Govindarajan / Haripriyan - Viewing Objectively - How OO Patterns led us to better FP adoption

    45 Mins
    Demonstration
    Beginner

    How do we start introducing functional constructs into a OOPs heavy project, without overwhelming the other developers? In our attempt to drive functional programming adoption, we tried to show how the existing OO patterns in the project and are inherently subsumed in a functional paradigm. This helped to make the concepts relatable and in due course increased adoption.

    Here we want to share our learning and show how most popular OO patterns can be expressed in a functional way.

help