tests using mocha and should, passing complex function tests in schema