I guess it to be a test. A test to see if Lion-O was worthy enough for the secrets the book possessed, a protection of the book so-to-speak, to make sure its secrets did not fall into the wrong hands.
The thing I don’t like about it, though, is we don’t know if that’s how Leo was or if that’s how the events of history played out.
So the question is, how much control did Lion-O have over his actions in the book. Leo’s knowledge or thoughts clearly had to be present in Lion-O’s mind. How else would he know how to use the computer interface. I’m not saying all of Leo’s original actions where exactly duplicated by Lion-O but maybe just certain things.
That part is right but the book acted like a simulation of the past. The others would have reacted according to Lion-o actions/words. He wasn’t send back in time. Its more like a holographic rpg game, his movement would have determine his outcome. I guess that was Jaga’s or the book way to see if Lion-o could unite the other races and defeat Mumm-ra, thats why Jaga warned him that if he failed the book would not remained open for him.
So we don’t know how the actual Leo played it out.