Fixed compile errors with Scala 2.11 in examples; added a test which runs the examples