浅层渲染:通过浅层渲染和轻松模拟,可以轻松进行角度测试。 https:getsaf.github.ioshallow-render

时间:2021-01-31 07:22:07
【文件属性】:
文件名称:浅层渲染:通过浅层渲染和轻松模拟,可以轻松进行角度测试。 https:getsaf.github.ioshallow-render
文件大小:201KB
文件格式:ZIP
更新时间:2021-01-31 07:22:07
testing mock angular typescript enzyme 浅色 通过浅浅的渲染和轻松的模拟,可以轻松进行角度测试。 文件 原理图 (感谢@mihalcan!) 文章 Angular版本支持 角度的 浅色 11倍 11倍 10倍 10倍 9倍 9倍 6x-8x 8倍 5倍 <= 7.2.0 超级简单的测试 describe ( 'ColorLinkComponent' , ( ) => { let shallow : Shallow < ColorLinkComponent> ; beforeEach ( ( ) => { shallow = new Shallow ( ColorLinkComponent , MyModule ) ; } ) ; it ( 'renders a link with the name of the color' , async ( ) => { const { find } = await shallow . render ( { bind : { color : 'Blue' } } ) ; // or shallow.render(`<color-link co

网友评论