Use Case best practice: Test your Use Cases with real data

Quite often when I’m asked to review a UML “Use Case” that someone else has written, I ask “Have you tested your Use Case with real data?” Sadly, the answer is usually “no.”

I don’t know why people don’t do this, but they don’t, and it seems like a very logical thing — essentially a unit test for Use Cases.

ScalaCheck custom generator examples

Table of Contents1 - Custom generators2 - Built-in ScalaCheck generators3 - How to use ScalaCheck generators4 - More ScalaCheck generators

Writing custom generators for ScalaCheck can be one of the more difficult and/or time-consuming parts of using it. As a result I thought I’d start putting together a list of generators that I have written or seen elsewhere. Unfortunately I can’t credit all the ones I’ve seen in other places because I google’d and copied them many moons ago, but I’ll give credit/attribution to all the ones I can.

Back to top

Custom generators

This is a combination of generators I wrote, and some that I copied from other places and may have modified a little:

JMH, an SBT plugin for running OpenJDK JMH benchmarks

JMH is an SBT plugin for running OpenJDK JMH benchmarks. Per its docs, “JMH is a Java harness for building, running, and analysing nano/micro/milli/macro benchmarks written in Java and other languages targeting the JVM.”

They also recommend reading an article titled Nanotrusting the Nanotime if you’re interested in writing your own benchmark tests.

Scala: Popular tools, libraries, and frameworks alvin June 15, 2018 - 9:53am
Table of Contents1 - Build tools2 - Testing tools3 - Database4 - Functional Programming5 - Asynchronous/parallel/concurrent programming6 - Web frameworks7 - JSON8 - HTTP clients9 - Configuration/properties10 - Many more

This page is a collection of popular tools, libraries, and frameworks for the Scala programming language.

Back to top

Build tools

“Sooner or later, we all go through a crucible”

“Sooner or later, we all go through a crucible ... Most believe there are two types of people who go into a crucible. The ones who become stronger from the experience and survive it, and the ones who die. But there’s a third type. The ones who learn to love the fire and choose to stay in their crucible because it’s easier to embrace the pain when it's all you know anymore.”

Sebastian Blood, Arrow

Fifty Shades of Mast Cell Activation Disease (MCAD/MCAS) alvin September 23, 2017 - 9:39am

Notes from September 24, 2016:

Doctor: I’d like to collect a bone marrow sample ...

*Al runs out of the hospital in a hospital gown, screaming like a little girl*

(later, after they caught me)

Doctor: The next time you break out in a rash, hives, or blisters, I want you to have those biopsied.

Me: Is there going to be any part of our relationship that doesn’t involve a lot of pain on my part?

Doc: Yes, pee in this cup, and we’ll look at it under a fluorescent light to see if you have the same disease that King George III had.

Me: The crazy one?

Doc: Yes.

Me: Cool.