Optional code parameter now even more optional. Unit tests.