Refactoring

Unbundling subsystem dependencies
Adapted and fixed tests