eonarheim / java-game-engine

Provides a simply easy to use 2D rpg game engine that is portable to anything that can run java.
2 stars 0 forks source link

Test cases desperately needed #5

Open eonarheim opened 12 years ago

eonarheim commented 12 years ago

It is way too easy to break the xml serialization in the current setup. We must have these test cases soon.

jcbrock commented 12 years ago

Stuff we discussed over coffee: Versioning needs to be figured out before we can really write a test case for how serialization/deserialization is going to work.

We could potentially use Java reflection to get the properties, and then compare each one of those. The problem with using reflection is that we will have several properties that are custom classes (like Actor, Level) and then the question is how to compare those to make sure they are equal.

We might have to bite the bullet and write brittle test cases that manully check each property, but we would need to make sure it would be easily updated to incorporate new properties as they get added. Again, we probably need to figure out versioning before any of this is done.

jcbrock commented 12 years ago

To be clear - the above comment is about serialization/deserialization test cases. Other test cases can be worked on.

eonarheim commented 11 years ago

You may need to added test cases for our timing code to make sure our deltas are being calculated correctly. Also test cases to ensure that our actions are ending in the proper places