< Summary

Information
Class: Minesweeper.MineItemModule
Assembly: Minesweeper
File(s): /home/runner/work/poc-fsharp-tdd-kata-minesweeper1/poc-fsharp-tdd-kata-minesweeper1/src/Minesweeper/MineItem.fs
Tag: 16_2290032055
Line coverage
33%
Covered lines: 9
Uncovered lines: 18
Coverable lines: 27
Total lines: 50
Line coverage: 33.3%
Branch coverage
30%
Covered branches: 8
Total branches: 26
Branch coverage: 30.7%
Method coverage

Method coverage is only available for sponsors.

Upgrade to PRO version

Coverage History

Metrics

MethodBranch coverage Cyclomatic complexity Line coverage
click(...)100%2100%
toString(...)25%1225%
add(...)25%1225%

File(s)

/home/runner/work/poc-fsharp-tdd-kata-minesweeper1/poc-fsharp-tdd-kata-minesweeper1/src/Minesweeper/MineItem.fs

#LineLine coverage
 1namespace Minesweeper
 2
 3type MineItem =
 4    | Covered of MineItem
 5    | Bomb
 6    | Zero
 7    | One
 8    | Two
 9    | Three
 10    | Four
 11    | Five
 12    | Six
 13    | Seven
 14    | Eight
 15
 16
 17module MineItem =
 18    let click v =
 219        match v with
 120        | Covered x -> x
 121        | x -> x
 22
 23    let toString v =
 224        match v with
 125        | Covered _ -> "."
 026        | Bomb -> "*"
 027        | Zero -> "0"
 028        | One -> "1"
 029        | Two -> "2"
 130        | Three -> "3"
 031        | Four -> "4"
 032        | Five -> "5"
 033        | Six -> "6"
 034        | Seven -> "7"
 035        | Eight -> "8"
 36
 37    let rec add v =
 238        match v with
 139        | Covered x -> Covered (add x)
 040        | Bomb -> Bomb
 041        | Zero -> One
 142        | One -> Two
 043        | Two -> Three
 044        | Three -> Four
 045        | Four -> Five
 046        | Five -> Six
 047        | Six -> Seven
 048        | Seven -> Eight
 049        | Eight -> Eight
 50