Fixed and added new test