I would like to mention http://exercism.io . It has unit tests written also
You mentioned tests: on exercism you don't write unit tests by yourself, the tests are only for you to check your solution. It certainly helps to see how tests can be written in any language, but you aren't forced into a strict TDD style.
The best feature on exercism for me is to be able to see the other solutions and learn from them.
One thing I like to have to write tests is actually practicing writing tests :)