Added test to test function assignment to delegate and fixed it in the process.