No. 12 Michigan State men's basketball was able to best No. 19 Illinois in what was one of its toughest tests of the season.