Fixed an existing test and code review changes

#1958