1、error "ProjectName-Swift.h" file not found
在单测的target中,Header Search Paths中添加
"$(TARGET_TEMP_DIR)/../$(PROJECT_NAME).build/DerivedSources"
2、bridging header warning
Implicit import of bridging header 'ProjectName-Bridging-Header.h' via module 'ProjectName' is deprecated and will be removed in a later version of Swift
在ProjectNameTests-Bridging-Header.h中引入#import "ProjectName-Bridging-Header.h"即可
3、error Cannot find 'ClassName' in scope
当前测试用例中使用,@testable import ProjectName