Adding fixes by ChamilaA for fixing unit tests