Fixed memory leak
Tests : slightly enhanced test framework
Tests : changed integration tests format to comply with the framework