SI-7616 Avoid ClassCastException in scala.concurrent.impl.ExecutionContextImpl

Adds test to scala-concurrent-tck