Mocha tests for the queries module