Implementing PHPUnit into framework for quality improvement.

Debug function core now changed. New error interface has been designed and available both Console and HTTP. // Need testing.