Slide 39
Slide 39 text
① テストの質を測る|mutation testing
カバレッジ100%でも、バグを見逃すテストがある
function isFreeShipping(total: number) { return total >= 5000 }
test('送料が無料になる', () => {
expect(isFreeShipping(10000)).toBe(true)
})
• このテストでカバレッジは100%
• 5,000円ちょうどの注文は確かめていない
©Flyle,Inc. All Rights Reserved
39