Using TestContainers in Scala with Spark for real unit testing
Briefly

In this quick post, we're going to set up a Scala project using SBT, and write a simple test that reads from a PostgreSQL database (created through TestContainers) using Spark.
The host where you run the tests needs to have docker running Java 8 / 11 Scala 2.12
Now, in the test folder of our project (scala-testing/src/test/scala/com/hypercodelab/testcontainers/), we are going to create a new test with the following code:
Read at Medium
[
add
]
[
|
|
]