Can confirm, got halfway wrecked in my upper div statistics midterm during COVID. 24 hours, open everything. Even the Internet can't replace real understanding.
Probably depends on the math. If it's descrete math, or anything where you have to prove something, having internet access isn't going to help (unless the test has been reused and uploaded). Either you can write a proof or you can't. Looking something up probably can only get your so far.