Test-Driven Development has become deservedly popular in the past decade, with easy-to-use xUnit unit testing frameworks leading the way toward encouraging developers to write tests. But xUnit has limitations: how does one know one has written enough test cases for a desired behavior? And what if the behavior is conditional on other behavior? Property-based testing, first popularized for Haskell with the QuickCheck library, but available now for other languages as well, offers a powerful addition to one's testing toolkit.
I will discuss the concepts of property-based testing and illustrate them concretely using ScalaCheck for Scala, and point toward similar test frameworks in other languages.
Watch video (in Hebrew): http://parleys.com/play/53f7a9cce4b06208c7b7ca1e
Type classes are a fundamental feature of Scala, which allows you to layer new functionality on top of existing types externally, i.e. without modifying or recompiling existing code. When combined with implicits, this is a truly remarkable tool that enables many of the advanced features offered by the Scala library ecosystem. In this talk we'll go back to basics: how type classes are defined and encoded, and cover several prominent use cases.
A talk given at the Underscore meetup on 19 August, 2014.
Watch video (in Hebrew): http://parleys.com/play/53f7a9cce4b06208c7b7ca1e
Type classes are a fundamental feature of Scala, which allows you to layer new functionality on top of existing types externally, i.e. without modifying or recompiling existing code. When combined with implicits, this is a truly remarkable tool that enables many of the advanced features offered by the Scala library ecosystem. In this talk we'll go back to basics: how type classes are defined and encoded, and cover several prominent use cases.
A talk given at the Underscore meetup on 19 August, 2014.
Video and slides synchronized, mp3 and slide download available at URL http://bit.ly/254wkpw.
Aaron Bedra focuses on describing a system as a series of models that can be used to systematically and automatically generate input data and ensure that a code is behaving as expected. Bedra discusses property based testing and how it can help one build more resilient systems and even reduce the time needed to maintain a test suite. Filmed at qconlondon.com.
Aaron Bedra is Chief Security Officer at eligible.com. He is the creator of Repsheet, an open source threat intelligence framework. Bedra is the co-author of Programming Clojure, 2nd Edition and a frequent contributor to open source software.
Video and more content at fsharpforfunandprofit.com/pbt
"The lazy programmer's guide to writing 1000's of tests: An introduction to property based testing"
We are all familiar with example-based testing, as typified by TDD and BDD. Property-based testing takes a very different approach, where a single test is run hundreds of times with randomly generated inputs.
Property-based testing is a great way to find edge cases, and also helps you to understand and document the behaviour of your code under all conditions.
This talk will introduce property-based testing and show how it works, and why you should consider adding it to your arsenal of testing tools.
In this presentation, You will get to know about Function Literal,Higher Order Function,Partial Function,Partial Applied Function,Nested Function,Closures.
Inspired by Josh Bloch's Java Puzzlers, we put together our own Python Puzzlers. This slide deck brings you a set of 10 python puzzlers, that are fun and educational. Each puzzler will show you a piece of python code. Your task if to figure out what happens when the code is run. Whether you're a python beginner or a passionate python veteran, we hope that there's something to learn for everybody.
This slide deck was first presented at shopkick. Nandan Sawant and Ryan Rueth are engineers at shopkick. Keeping the audience in mind, most of the puzzlers are based on python 2.x.
Video and slides synchronized, mp3 and slide download available at URL http://bit.ly/254wkpw.
Aaron Bedra focuses on describing a system as a series of models that can be used to systematically and automatically generate input data and ensure that a code is behaving as expected. Bedra discusses property based testing and how it can help one build more resilient systems and even reduce the time needed to maintain a test suite. Filmed at qconlondon.com.
Aaron Bedra is Chief Security Officer at eligible.com. He is the creator of Repsheet, an open source threat intelligence framework. Bedra is the co-author of Programming Clojure, 2nd Edition and a frequent contributor to open source software.
Video and more content at fsharpforfunandprofit.com/pbt
"The lazy programmer's guide to writing 1000's of tests: An introduction to property based testing"
We are all familiar with example-based testing, as typified by TDD and BDD. Property-based testing takes a very different approach, where a single test is run hundreds of times with randomly generated inputs.
Property-based testing is a great way to find edge cases, and also helps you to understand and document the behaviour of your code under all conditions.
This talk will introduce property-based testing and show how it works, and why you should consider adding it to your arsenal of testing tools.
In this presentation, You will get to know about Function Literal,Higher Order Function,Partial Function,Partial Applied Function,Nested Function,Closures.
Inspired by Josh Bloch's Java Puzzlers, we put together our own Python Puzzlers. This slide deck brings you a set of 10 python puzzlers, that are fun and educational. Each puzzler will show you a piece of python code. Your task if to figure out what happens when the code is run. Whether you're a python beginner or a passionate python veteran, we hope that there's something to learn for everybody.
This slide deck was first presented at shopkick. Nandan Sawant and Ryan Rueth are engineers at shopkick. Keeping the audience in mind, most of the puzzlers are based on python 2.x.
Halifax’s Finance and Insurance Industry: Our OpportunityHalifax Partnership
Since its incorporation in 1841, Halifax has always been a significant financial centre in Canada. In
recent years, the community has been positioned as the regional financial hub for the Canadian
fi nancial services industry.
Caching Search Engine Results over Incremental IndicesRoi Blanco
A Web search engine must update its index periodically to incorporate changes to the Web. We argue in this paper that index updates fundamentally impact the design of search engine result caches, a performance-critical component of modern search engines. Index updates lead to the problem of cache invalidation: invalidating cached entries of queries whose results have changed. Naive approaches, such as flushing the entire cache upon every index update, lead to poor performance and in fact, render caching futile when the frequency of updates is high. Solving the invalidation problem efficiently corresponds to predicting accurately which queries will produce different results if re-evaluated, given the actual changes to the index.
To obtain this property, we propose a framework for developing invalidation predictors and define metrics to evaluate invalidation schemes. We describe concrete predictors using this framework and compare them against a baseline that uses a cache invalidation scheme based on time-to-live (TTL). Evaluation over Wikipedia documents using a query log from the Yahoo! search engine shows that selective invalidation of cached search results can lower the number of unnecessary query evaluations by as much as 30% compared to a baseline scheme, while returning results of similar freshness. In general, our predictors enable fewer unnecessary invalidations and fewer stale results compared to a TTL-only scheme for similar freshness of results.
Actors testing is different from what you are used to. First, you have messages instead of calls, second, you have to deal with concurrency and all the consequences that it brings with it:
* Thread.sleeps in tests;
* Flakiness;
* Green on laptop / red on jenkins;
* Missed test cases.
Fortunately Akka provides a TestKit which helps to avoid all these things when used properly. Let's take out and inspect tools from this kit and learn couple of useful patterns.
When you write unit tests for your projects, there’s a fair chance that you do so by following the classical « Given-When-Then » paradigm, in which you set some input data, execute the code you’re testing, and finally assert that its outcome is indeed the one you expected.
While this approach is perfectly sound, it does suffer one downside: your program will only be tested on the static input data defined in your tests, and there is no real guarantee that this data does cover all edge cases. This can be especially problematic for SDK developers, who, by definition, have a very hard time anticipating all the different situations in which their code will be used.
To improve on this issue, another approach exists, and it is called property-based testing. The idea behind it is very simple: you write your tests by defining properties that must always be true for your program. For example, « an array reversed twice is always equal to itself ». The testing framework will then generate random input values and test wether the property holds or not. And, as you can imagine, this approach is extremely good at narrowing down on overlooked edge cases.
In Swift, we are lucky enough to already have a full-fledged implementation called SwiftCheck, that enables property-based testing (https://github.com/typelift/SwiftCheck). The goal of this talk is thus to explain how property-based testing can be a powerful addition to a testing suite, and give actual and actionable examples of how it can be added to a project using SwiftCheck.
Principles of functional progrmming in scalaehsoon
a short outline on necessity of functional programming and principles of functional programming in Scala.
In the article some keyword are used but not explained (to keep the article short and simple), the interested reader can look them up in internet.
JavaScript - An Introduction is a beginner's guide to JavaScript. It starts with very basic level and goes to intermediate level. You'll be introduced with every language constructs, Event handling, Form handling and AJAX which is supported by JavaScript with XMLHttpRequest object. This XHR object is discussed in enough detail so that you can understand how the underlying AJAX functionality works in jQuery. At the end it discusses advance concepts and library build on/around JavaScript.
SOCRadar Research Team: Latest Activities of IntelBrokerSOCRadar
The European Union Agency for Law Enforcement Cooperation (Europol) has suffered an alleged data breach after a notorious threat actor claimed to have exfiltrated data from its systems. Infamous data leaker IntelBroker posted on the even more infamous BreachForums hacking forum, saying that Europol suffered a data breach this month.
The alleged breach affected Europol agencies CCSE, EC3, Europol Platform for Experts, Law Enforcement Forum, and SIRIUS. Infiltration of these entities can disrupt ongoing investigations and compromise sensitive intelligence shared among international law enforcement agencies.
However, this is neither the first nor the last activity of IntekBroker. We have compiled for you what happened in the last few days. To track such hacker activities on dark web sources like hacker forums, private Telegram channels, and other hidden platforms where cyber threats often originate, you can check SOCRadar’s Dark Web News.
Stay Informed on Threat Actors’ Activity on the Dark Web with SOCRadar!
Large Language Models and the End of ProgrammingMatt Welsh
Talk by Matt Welsh at Craft Conference 2024 on the impact that Large Language Models will have on the future of software development. In this talk, I discuss the ways in which LLMs will impact the software industry, from replacing human software developers with AI, to replacing conventional software with models that perform reasoning, computation, and problem-solving.
Navigating the Metaverse: A Journey into Virtual Evolution"Donna Lenk
Join us for an exploration of the Metaverse's evolution, where innovation meets imagination. Discover new dimensions of virtual events, engage with thought-provoking discussions, and witness the transformative power of digital realms."
top nidhi software solution freedownloadvrstrong314
This presentation emphasizes the importance of data security and legal compliance for Nidhi companies in India. It highlights how online Nidhi software solutions, like Vector Nidhi Software, offer advanced features tailored to these needs. Key aspects include encryption, access controls, and audit trails to ensure data security. The software complies with regulatory guidelines from the MCA and RBI and adheres to Nidhi Rules, 2014. With customizable, user-friendly interfaces and real-time features, these Nidhi software solutions enhance efficiency, support growth, and provide exceptional member services. The presentation concludes with contact information for further inquiries.
Developing Distributed High-performance Computing Capabilities of an Open Sci...Globus
COVID-19 had an unprecedented impact on scientific collaboration. The pandemic and its broad response from the scientific community has forged new relationships among public health practitioners, mathematical modelers, and scientific computing specialists, while revealing critical gaps in exploiting advanced computing systems to support urgent decision making. Informed by our team’s work in applying high-performance computing in support of public health decision makers during the COVID-19 pandemic, we present how Globus technologies are enabling the development of an open science platform for robust epidemic analysis, with the goal of collaborative, secure, distributed, on-demand, and fast time-to-solution analyses to support public health.
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus
As part of the DOE Integrated Research Infrastructure (IRI) program, NERSC at Lawrence Berkeley National Lab and ALCF at Argonne National Lab are working closely with General Atomics on accelerating the computing requirements of the DIII-D experiment. As part of the work the team is investigating ways to speedup the time to solution for many different parts of the DIII-D workflow including how they run jobs on HPC systems. One of these routes is looking at Globus Compute as a way to replace the current method for managing tasks and we describe a brief proof of concept showing how Globus Compute could help to schedule jobs and be a tool to connect compute at different facilities.
Enhancing Research Orchestration Capabilities at ORNL.pdfGlobus
Cross-facility research orchestration comes with ever-changing constraints regarding the availability and suitability of various compute and data resources. In short, a flexible data and processing fabric is needed to enable the dynamic redirection of data and compute tasks throughout the lifecycle of an experiment. In this talk, we illustrate how we easily leveraged Globus services to instrument the ACE research testbed at the Oak Ridge Leadership Computing Facility with flexible data and task orchestration capabilities.
How to Position Your Globus Data Portal for Success Ten Good PracticesGlobus
Science gateways allow science and engineering communities to access shared data, software, computing services, and instruments. Science gateways have gained a lot of traction in the last twenty years, as evidenced by projects such as the Science Gateways Community Institute (SGCI) and the Center of Excellence on Science Gateways (SGX3) in the US, The Australian Research Data Commons (ARDC) and its platforms in Australia, and the projects around Virtual Research Environments in Europe. A few mature frameworks have evolved with their different strengths and foci and have been taken up by a larger community such as the Globus Data Portal, Hubzero, Tapis, and Galaxy. However, even when gateways are built on successful frameworks, they continue to face the challenges of ongoing maintenance costs and how to meet the ever-expanding needs of the community they serve with enhanced features. It is not uncommon that gateways with compelling use cases are nonetheless unable to get past the prototype phase and become a full production service, or if they do, they don't survive more than a couple of years. While there is no guaranteed pathway to success, it seems likely that for any gateway there is a need for a strong community and/or solid funding streams to create and sustain its success. With over twenty years of examples to draw from, this presentation goes into detail for ten factors common to successful and enduring gateways that effectively serve as best practices for any new or developing gateway.
Into the Box Keynote Day 2: Unveiling amazing updates and announcements for modern CFML developers! Get ready for exciting releases and updates on Ortus tools and products. Stay tuned for cutting-edge innovations designed to boost your productivity.
Quarkus Hidden and Forbidden ExtensionsMax Andersen
Quarkus has a vast extension ecosystem and is known for its subsonic and subatomic feature set. Some of these features are not as well known, and some extensions are less talked about, but that does not make them less interesting - quite the opposite.
Come join this talk to see some tips and tricks for using Quarkus and some of the lesser known features, extensions and development techniques.
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...Globus
Large Language Models (LLMs) are currently the center of attention in the tech world, particularly for their potential to advance research. In this presentation, we'll explore a straightforward and effective method for quickly initiating inference runs on supercomputers using the vLLM tool with Globus Compute, specifically on the Polaris system at ALCF. We'll begin by briefly discussing the popularity and applications of LLMs in various fields. Following this, we will introduce the vLLM tool, and explain how it integrates with Globus Compute to efficiently manage LLM operations on Polaris. Attendees will learn the practical aspects of setting up and remotely triggering LLMs from local machines, focusing on ease of use and efficiency. This talk is ideal for researchers and practitioners looking to leverage the power of LLMs in their work, offering a clear guide to harnessing supercomputing resources for quick and effective LLM inference.
Field Employee Tracking System| MiTrack App| Best Employee Tracking Solution|...informapgpstrackings
Keep tabs on your field staff effortlessly with Informap Technology Centre LLC. Real-time tracking, task assignment, and smart features for efficient management. Request a live demo today!
For more details, visit us : https://informapuae.com/field-staff-tracking/
Software Engineering, Software Consulting, Tech Lead.
Spring Boot, Spring Cloud, Spring Core, Spring JDBC, Spring Security,
Spring Transaction, Spring MVC,
Log4j, REST/SOAP WEB-SERVICES.
First Steps with Globus Compute Multi-User EndpointsGlobus
In this presentation we will share our experiences around getting started with the Globus Compute multi-user endpoint. Working with the Pharmacology group at the University of Auckland, we have previously written an application using Globus Compute that can offload computationally expensive steps in the researcher's workflows, which they wish to manage from their familiar Windows environments, onto the NeSI (New Zealand eScience Infrastructure) cluster. Some of the challenges we have encountered were that each researcher had to set up and manage their own single-user globus compute endpoint and that the workloads had varying resource requirements (CPUs, memory and wall time) between different runs. We hope that the multi-user endpoint will help to address these challenges and share an update on our progress here.
Custom Healthcare Software for Managing Chronic Conditions and Remote Patient...Mind IT Systems
Healthcare providers often struggle with the complexities of chronic conditions and remote patient monitoring, as each patient requires personalized care and ongoing monitoring. Off-the-shelf solutions may not meet these diverse needs, leading to inefficiencies and gaps in care. It’s here, custom healthcare software offers a tailored solution, ensuring improved care and effectiveness.
Globus Connect Server Deep Dive - GlobusWorld 2024Globus
We explore the Globus Connect Server (GCS) architecture and experiment with advanced configuration options and use cases. This content is targeted at system administrators who are familiar with GCS and currently operate—or are planning to operate—broader deployments at their institution.
Cyaniclab : Software Development Agency Portfolio.pdfCyanic lab
CyanicLab, an offshore custom software development company based in Sweden,India, Finland, is your go-to partner for startup development and innovative web design solutions. Our expert team specializes in crafting cutting-edge software tailored to meet the unique needs of startups and established enterprises alike. From conceptualization to execution, we offer comprehensive services including web and mobile app development, UI/UX design, and ongoing software maintenance. Ready to elevate your business? Contact CyanicLab today and let us propel your vision to success with our top-notch IT solutions.
Enterprise Resource Planning System includes various modules that reduce any business's workload. Additionally, it organizes the workflows, which drives towards enhancing productivity. Here are a detailed explanation of the ERP modules. Going through the points will help you understand how the software is changing the work dynamics.
To know more details here: https://blogs.nyggs.com/nyggs/enterprise-resource-planning-erp-system-modules/
Beyond xUnit example-based testing: property-based testing with ScalaCheck
1. Beyond xUnit example-based testing:
property-based testing with ScalaCheck
Franklin Chen
http://franklinchen.com/
Pittsburgh Scala Meetup
April 11, 2013
2. Our goal: software correctness
Use all available tools that are practical in context.
Static type system
We are Scala users!
Two extremes
Automated theorem proving
Testing
What is practical?
3. Theorem proving
Example: list append
// Given an implementation in ListOps of:
def append[A](xs: List[A], ys: List[A]): List[A]
How prove this property without a shadow of a doubt?
// for all lists xs and ys
ListOps.append(xs, ys).length == xs.length + y.length
Not (yet) practical in most contexts.
(Scala compiler cannot prove this property.)
4. More powerful static type system: dependent types
Try using a more powerful language?
Example: Idris language, based on Haskell
Type checks!
(++) : Vect A n -> Vect A m -> Vect A (n + m)
(++) Nil ys = ys
(++) (x :: xs) ys = x :: xs ++ ys
Still research, however.
Also: Scala libraries such as shapeless pushing the edge of
Scala’s type system.
Not (yet) practical for most of us.
5. Testing
Goals?
Give up goal of mathematical guarantee of correctness.
Try to gain confidence that our code might be “probably” or
“mostly” correct.
Still a young field. Recent report on the state of testing: SEI
blog
Remember to be humble when testing; avoid overconfidence!
6. Example-based testing
xUnit frameworks such as JUnit
Hand-craft specific example scenarios, make assertions
Popular Scala test frameworks that support xUnit style testing:
ScalaTest
specs2
For concreteness: I test with specs2, with SBT.
7. Individual examples of list append
// Individually hand-crafted examples
ListOps.append(List(3), List(7, 2)).length must_==
List(3).length + List(7, 2).length
ListOps.append(List(3, 4), List(7, 2)).length must_==
List(3, 4).length + List(7, 2).length
// ...
Tedious to set up each example, one by one.
Are we confident that we listed all the relevant cases,
including corner cases?
8. Refactoring to a data table
// Hand-crafted table of data, but logic is factored out
"xs" | "ys" |
List(3) ! List(7, 2) |
List(3, 4) ! List(7, 2) |> {
(xs, ys) =>
ListOps.append(xs, ys).length must_==
xs.length + ys.length
}
Note: latest JUnit supports parameterized tests also.
9. Property-based testing: introducing ScalaCheck
ScalaCheck library
Port of Haskell QuickCheck
Use standalone, or within ScalaTest or specs2
Write down what we really intend, a universal property!
prop {
(xs: List[Int], ys: List[Int]) =>
ListOps.append(xs, ys).length must_==
xs.length + ys.length
}
ScalaCheck automatically generates 100 random test cases (the
default number) and runs them successfully!
10. Property-based testing: fake theorem proving?
Theorem proving is hard.
ScalaCheck allows us to pretend we are theorem proving,
with caveats:
How random are the generated data?
How useful for our desired corner cases?
How can we customize the generation?
How reproducible is the test run?
How confident can we be in the coverage?
Property-based testing is still an area of research.
But it is already useful as it is.
11. A failing test reports a minimal counter-example
What is wrong with this property about multiplication and division?
prop {
(x: Int, y: Int) => (x * y) / y must_== x
}
Output:
> test
ArithmeticException: A counter-example is [0, 0]:
java.lang.ArithmeticException: / by zero
Oops, our test was sloppy!
12. Introducing conditional properties
Exclude dividing by 0: use conditional operator ==> with forAll:
prop {
x: Int =>
forAll {
y: Int =>
(y != 0) ==> { (x * y) / y must_== x }
}
}
Generate random x.
Generate random y, but discard test case if conditions fails.
All good now?
13. Testing as an iterative process
Still get a counter-example.
Int overflow.
> test
A counter-example is [2, 1073741824]
(after 2 tries - shrinked
(’452994647’ -> ’2’,’-2147483648’ -> ’1073741824’))
’-2’ is not equal to ’2’
Writing and refining a property guides our understanding of the
problem.
14. The joy of experimental testing
ScalaCheck discovered an unexpected edge case for us!
Write a general property before coding.
Write the code.
ScalaCheck gives counter-example.
Choice:
Fix code.
Fix property.
Run ScalaCheck again until test passes.
15. Choice 1: fix code
Assume we want our high-level property, of multiplying and
dividing of integers, to hold.
Choose a different representation of integer in our application:
replace Int with BigInt:
prop {
x: BigInt =>
forAll {
y: BigInt =>
(y != 0) ==> { (x * y) / y must_== x }
}
}
Success!
16. Choice 2: fix property
Assume we only care about a limited range of Int.
Use a generator Gen.choose, for example:
forAll(Gen.choose(0, 10000), Gen.choose(1, 10000)) {
(x: Int, y: Int) => { (x * y) / y must_== x }
}
Success!
17. Introduction to custom generators: why?
Attempted property:
prop {
(x: Int, y: Int, z: Int) =>
(x < y && y < z) ==> x < z
}
Output:
> test
Gave up after only 28 passed tests.
142 tests were discarded.
Reason: too many x, y, z test cases that did not satisfy the
condition.
18. Introduction to custom generators: how?
Try to generate data likely to be useful for the property.
Use arbitrary generator, Gen.choose generator, and
for-comprehension:
val orderedTriples = for {
x <- arbitrary[Int]
y <- Gen.choose(x + 1, Int.MaxValue)
z <- Gen.choose(y + 1, Int.MaxValue)
} yield (x, y, z)
forAll(orderedTriples) {
case (x, y, z) =>
(x < y && y < z) ==> x < z
}
Success!
19. More complex custom generator: sorted lists
Assume we want to specify the behavior of a function that inserts
an integer into a sorted list to return a new sorted list:
def insert(x: Int, xs: List[Int]): List[Int]
We first try
prop {
(x: Int, xs: List[Int]) =>
isSorted(xs) ==> isSorted(insert(x, xs))
}
where we have already defined
def isSorted(xs: List[Int]): Boolean
20. Not constrained enough
Too many generated lists are not sorted.
> test-only *ListCheckSpec
Gave up after only 10 passed tests.
91 tests were discarded.
So let’s write a custom generator someSortedLists, to use with
the property
forAll(someSortedLists) {
xs: List[Int] => prop {
x: Int =>
isSorted(xs) ==> isSorted(insert(x, xs))
}
}
21. Custom generator for sorted lists
Choose a list size.
Choose a starting integer x.
Choose a list with first element at least x.
val someSortedLists = for {
size <- Gen.choose(0, 1000)
x <- arbitrary[Int]
xs <- sortedListsFromAtLeast(size, x)
} yield xs
Now implement our sortedListsFromAtLeast.
22. Generating the sorted list
/**
@return generator of a sorted list of length size
with first element >= x
*/
def sortedListsFromAtLeast(size: Int, x: Int):
Gen[List[Int]] = {
if (size == 0) {
Nil
}
else {
for {
y <- Gen.choose(x, x+100)
ys <- sortedListsFromAtLeast(size-1, y)
} yield y::ys
}
}
23. What is going on? Classifiers
Gather statistics about the nature of the generated data. One way:
classifiers.
forAll(someSortedLists) {
xs: List[Int] => classify(xs.length < 300,
"length 0-299") {
classify(xs.length >= 300 && xs.length < 800,
"length 300-799") {
classify(xs.length >= 800,
"length 800+") {
prop {
x: Int =>
isSorted(xs) ==> isSorted(insert(x, xs))
}
}
}
}
}
25. Much more!
Examples not covered today.
Built-in support for generating sized containers.
Specify custom frequencies when choosing alternatives.
Generate objects such as trees.
Generate functions.
Supply own random number generator.
Stateful testing.
26. Warning: false sense of security
Automated testing: good
Lots and lots of tests: good?
Fallacy of big data overoptimism
Testing is not proof: absence of evidence of bugs does not equal
evidence of absence of bugs.
27. Other property-based testing tools
ScalaCheck has known limitations:
Not always easy to write good generator.
Random generation does not provide complete coverage.
Tests do not give the same results when run again.
Alternatives:
SmallCheck for Haskell
Apparently ported to Scala
Active area of research
28. The TDD community
JUnit incorporating some property-based ideas in the new
feature called Theories
Many other programming languages gaining property-based
testing!
Nat Pryce of Growing Obect-Oriented Software Guided by
Tests giving workshops on property-based TDD
29. Conclusion
Automated testing is good.
Property-based testing: put into your toolbox.
If you use Scala: use ScalaCheck.
If you use Java: use ScalaCheck!
Be aware of limitations of testing.
Have fun!
All materials for this talk available at
https://github.com/franklinchen/talk-on-scalacheck.