Converted the test case to nodeunit test case