Add tests for method ex1.