fixed tests and structure