ScaTDD: Casting an eye over three major Test frameworks in Scala
Testing has traditionally been the gateway process for Scala
development at a number of Java shops looking to evolve their
tech stack with minimal disruption or committment. This posts
hopes to cover three of the main testing frameworks in the Scala
landscape, ( Specs2, Scalatest and Scalacheck) with an example
of the classic FizzBuzz test, for how they can be used for fun
and profit. So, the brief outline of the FizzBuzz requirement
are that given a sequence of numbers:    • Any number divisible
by 3 should return the String “Fizz”   • Any number divisible by
5 should return the String “Buzz”   • Any number divisible by
both 3 and 5 should return the String “FizzBuzz”   • Otherwise
the number should be returned as a String  As a comparison, I’ve
also included a sample Java JUnit test for this. The actual
implementation code (included here) for this is trivial, (partly
by design) as it is just to show illustrate the libraries being
used.      