Updated deprecated packages and methods
Fixed tests with incorrect Mock assertion usage of equals to use isEqualTo.