Fix destructor
Fix unit tests
Fix CS