Removed duplicate functions, moved in tests for common from fossa project