home.social

#quickcheck — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #quickcheck, aggregated by home.social.

fetched live
  1. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  2. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  3. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  4. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  5. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  6. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  7. Started hacking on a shrinker (reducer) of floats for QCheck a while back - and struggled. Yesterday I finally made some progress and now opened a PR for it:
    github.com/c-cube/qcheck/pull/ ✂️ 🔢 🤓

    #ocaml #pbt #quickcheck

  8. Here's a preprint of the paper I wrote up for Olivier's festscrift 🎉 🍾

    Property-Based Testing of OCaml 5's Runtime System:
    Fun and Segfaults with Interpreters and State Transition Functions

    We describe our effort on using property-based testing to test the OCaml 5 multicore runtime system. In particular, we cover three case studies of increasing complexity that utilize a model-based state machine framework: (a) Testing the Array module, (b) testing weak hash sets, and (c) testing the garbage collector, with the latter two behaving non-deterministically from the point of view of the blackbox testing process. We evaluate the approach empirically by analyzing the bugs found, and discuss both limitations and challenges we have met underway.

    janmidtgaard.dk/papers/Midtgaa

    #ocaml #pbt #quickcheck #preprint

  9. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  10. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  11. Property-based testing in Haskell with QuickCheck falsify

    A few days ago, Edsko de Vries of Well-Typed published an in-depth article on property-based software testing, with a focus on the concept of “shrinking.”

    In brief, property-based testing is sort-of like fuzz testing but for algorithms and protocols. Like fuzz testing, random test cases are procedurally generated, but unlike fuzz testing, the test cases are carefully designed to verify whether a software implementation of an algorithm satisfies a specific property of that algorithm, such as:

    • “this function always fails if the index is larger than the array”
    • “this function always returns a result in n*log(n) number of iterations for input dataset of size n
    • “the sequence of log messages is guaranteed to obey this rules of this particular finite-state automata: (connect | fail) -> (send X | fail) -> (receive Y | receive Z | fail) -> success .”

    Shrinking is the process of simplifying a failed test case. If you have found some input that makes your function return a value when it should have thrown an exception, or produce a result that does not satisfy some predicate, then that input is a “counterexample” to your assertion about the properties of that function. And you may want to be able to “shrink” that counterexample input to see if you can cause the function to behave incorrectly again but with a simpler input. The “QuickCheck“ library provides a variety of useful tools to let you define property tests with shrinking.

    Defining unit tests with such incredible rigor takes quite a lot of time and effort, so you would probably do not want to use property-based testing for your ordinary, every-day software engineering. If you are, for example, being scrutinized by the US Department of Government of Efficiency, you would likely be fired if you were to take so much time to write such high-quality software with such a strong guarantee of correctness.

    But if you are, for example, designing a communication protocol that will be used in critical infrastructure for the next 10 or 20 years and you want to make sure the reference implementation of your protocol is without contradictions, or if you are implementing an algorithm where the mathematical properties of the algorithm fall within some proven parameters (e.g. computational complexity), property-based testing can give you a much higher degree of confidence in the correctness of your algorithm or protocol specification.

    #tech #software #haskell #WellTyped #QuickCheck #UnitTesting #PropertyTesting

  12. Property-based testing in Haskell with QuickCheck falsify

    A few days ago, Edsko de Vries of Well-Typed published an in-depth article on property-based software testing, with a focus on the concept of “shrinking.”

    In brief, property-based testing is sort-of like fuzz testing but for algorithms and protocols. Like fuzz testing, random test cases are procedurally generated, but unlike fuzz testing, the test cases are carefully designed to verify whether a software implementation of an algorithm satisfies a specific property of that algorithm, such as:

    • “this function always fails if the index is larger than the array”
    • “this function always returns a result in n*log(n) number of iterations for input dataset of size n
    • “the sequence of log messages is guaranteed to obey this rules of this particular finite-state automata: (connect | fail) -> (send X | fail) -> (receive Y | receive Z | fail) -> success .”

    Shrinking is the process of simplifying a failed test case. If you have found some input that makes your function return a value when it should have thrown an exception, or produce a result that does not satisfy some predicate, then that input is a “counterexample” to your assertion about the properties of that function. And you may want to be able to “shrink” that counterexample input to see if you can cause the function to behave incorrectly again but with a simpler input. The “QuickCheck“ library provides a variety of useful tools to let you define property tests with shrinking.

    Defining unit tests with such incredible rigor takes quite a lot of time and effort, so you would probably do not want to use property-based testing for your ordinary, every-day software engineering. If you are, for example, being scrutinized by the US Department of Government of Efficiency, you would likely be fired if you were to take so much time to write such high-quality software with such a strong guarantee of correctness.

    But if you are, for example, designing a communication protocol that will be used in critical infrastructure for the next 10 or 20 years and you want to make sure the reference implementation of your protocol is without contradictions, or if you are implementing an algorithm where the mathematical properties of the algorithm fall within some proven parameters (e.g. computational complexity), property-based testing can give you a much higher degree of confidence in the correctness of your algorithm or protocol specification.

    #tech #software #haskell #WellTyped #QuickCheck #UnitTesting #PropertyTesting

  13. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  14. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  15. [Перевод] Исследуем монады в Rust через тестирование на основе свойств

    В педагогике программирования монады занимают место мистического объекта из мира функционального программирования, который трудно понять и еще труднее объяснить. Стереотип о сложности объяснения монад заключается в том, что они делятся на две категории: либо сравнение с каким-то продуктом питания , либо написание сложного математического жаргона, в чем проблема?

    habr.com/ru/articles/887234/

    #Rust #quickcheck #monad #propertybasedtesting

  16. Over the past couple of days, I've been scratching a 3-year old QCheck(2) itch
    github.com/c-cube/qcheck/pull/
    It's nice to finally make progress on it! 😃
    #ocaml #quickcheck #pbt #fp

  17. I've written up part 2 on our effort to utilize property-based testing to stress test the OCaml 5 run time system. Happy Christmas reading! 🎄🎅 🎁 😄
    tarides.com/blog/2024-12-23-mu
    #ocaml #pbt #fp #functionalprogramming #quickcheck

  18. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  19. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  20. I'll visit Paris this week to give a talk about our efforts to drill OCaml 5 with property-based tests: sites.google.com/view/gdr-gpl-

    Ping me if we should hook up for a coffee or a beer... ☕🍺

    #pbt #quickcheck #ocaml

  21. This description from a crash fix PR yesterday by Stephen Dolan put a smile on my face: 😀
    "With the old code, the following sequence of unfortunate events can occur, if you are very, very unlucky (or you are @jmid with multicoretests, manufacturing bad luck on an industrial scale):"
    github.com/ocaml/ocaml/pull/13
    #quickcheck #pbt #propertybasedtesting

  22. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  23. Discover the power of property-based testing in R with the #quickcheck package! Seamlessly integrates with #testthat and offers a variety of generators for atomic vectors, lists, and tibbles. Perfect for ensuring your code's reliability. Check it out: github.com/armcn/quickcheck #rstats #rprogramming #testing

  24. I found the problem!

    The default number of times QuickCheck will shrink a test case is "maxBound :: Int" or 9223372036854775807 shrinks.

    One of my shrink functions was returning the same input and telling #QuickCheck the new value was smaller.

    #haskell

    When an exception was thrown in the test case, QuickCheck would try to find a smaller failing value, and I was never patient enough to wait for 9223372036854775807 shrinks.

  25. I found the problem!

    The default number of times QuickCheck will shrink a test case is "maxBound :: Int" or 9223372036854775807 shrinks.

    One of my shrink functions was returning the same input and telling #QuickCheck the new value was smaller.

    #haskell

    When an exception was thrown in the test case, QuickCheck would try to find a smaller failing value, and I was never patient enough to wait for 9223372036854775807 shrinks.

  26. Can anyone recommend some projects that actually use in the wild (specifically, I'm looking for more realistic usage than the countless tutorials that go as far as "here are some properties that test if a list is sorted")?

    I'm familiar with Scott Wlaschin's series, which is great, but I'd really like to see some production examples.

  27. The funny story of a bug starring Unicode, C, regexps, libunistring, and ASCII:
    issues.guix.gnu.org/48114#4

    All this because of ⒒ And thanks to #QuickCheck.

  28. It can be really hard to predict how to test some software's actions without replicating its implementation. That strategy is a problem: it doesn't test whether it functions correctly. John Hughes (#haskell, #quickcheck) addressed this in a talk last year. infoq.com/news/2020/02/propert

  29. "Of course there are many excellent tutorials out there already. However I found all of them either assumed too much knowledge. I hope this post closes a gap in the current menu of tutorials..."

    jesper.sikanda.be/posts/quickc

  30. Taking time to learn about in today.

  31. Just create a simple bubble sort implementation in #rust with #proptest based property testing.

    #quickcheck

  32. I just learned that the #QuickCheck implementation for #Coq is called QuickChick… oh boy 😸