单元测试 1.Set Internal Class Visible [assembly:InternalsVisibleTo("UnitTest")] 主要是为了单元测试的时候又不需要破坏原有的代码可见性. 2.Mock 模拟对象来测试