It’s because in your code the timer update after button click happens in two passes: first you change increaseSession to trigger useEffect (1st pass) which changes sessionLength and minutes (2nd pass).
You can’t see it because it happens very fast, but tests can catch it.
Overall, the way you use useEffect is not quite right. You should go with a regular onClick handler which updates all the necessary variables (you really don’t need useEffect to handle clicks).
Here’s an example (look at lines 124 and 286): https://codepen.io/jenovs/pen/PoqNWEx?editors=0010