Refactor of tests and files structure