Can you have simple unit tests for complicated function?
The Turing test would make a very poor unit test because (a) it is difficult (impossible ?) to automate and (b) the evaluation of the test output to produce a pass or fail result is subjective. In fact, it might not even be possible to devise useful unit tests (in the usual sense) for strong AI - how would unit tests distinguish between true AI and a program that simply responded by rote ?

But simple unit tests for other complicated functions are certainly possible. As long as the function produces output that can be objectively evaluated then you can write unit test cases for it. For example, a Travelling Salesman Problem solver could be a very complicated program, but a unit test plan is very simple:

(a) test edge cases - 0 cities, 1 city, 2 cities

(b) test some simple cases with known solutions e.g. 3 cities in scalene triangle, 4 cities at corners of a rectangle, solved examples from TSPLIB