Refactor directory structure and add sausage lib for functional tests