added a test for the optional param case