Migrate unit tests to XCTest