made the engine follow the singleton pattern.

altered other classes and test cases to follow the updated engine

Signed-off-by: Nicholas Lum <nicholaslum444@hotmail.com>