mark rookies in goalieSummary
This commit is contained in:
parent
5209c4a296
commit
ee3cea5643
|
@ -31,7 +31,7 @@ goalieDetails :: Goalie -> String
|
||||||
goalieDetails g = let
|
goalieDetails g = let
|
||||||
header = unlines $ labelTable
|
header = unlines $ labelTable
|
||||||
[ ( "Number", show $ g^.gNumber )
|
[ ( "Number", show $ g^.gNumber )
|
||||||
, ( "Name", g^.gName )
|
, ( "Name", goalieName g )
|
||||||
]
|
]
|
||||||
|
|
||||||
body = unlines $ numTable ["YTD", "Lifetime"] $ map
|
body = unlines $ numTable ["YTD", "Lifetime"] $ map
|
||||||
|
|
|
@ -35,6 +35,7 @@ spec = describe "Goalie" $ do
|
||||||
goalieDetailsSpec :: Spec
|
goalieDetailsSpec :: Spec
|
||||||
goalieDetailsSpec = describe "goalieDetails" $ let
|
goalieDetailsSpec = describe "goalieDetails" $ let
|
||||||
input = newGoalie 1 "Joe"
|
input = newGoalie 1 "Joe"
|
||||||
|
& gRookie .~ True
|
||||||
& gYtd
|
& gYtd
|
||||||
%~ ( gsGames .~ 2 )
|
%~ ( gsGames .~ 2 )
|
||||||
. ( gsMinsPlayed .~ 3 )
|
. ( gsMinsPlayed .~ 3 )
|
||||||
|
@ -54,7 +55,7 @@ goalieDetailsSpec = describe "goalieDetails" $ let
|
||||||
|
|
||||||
expected = unlines
|
expected = unlines
|
||||||
[ "Number: 1"
|
[ "Number: 1"
|
||||||
, " Name: Joe"
|
, " Name: Joe*"
|
||||||
, ""
|
, ""
|
||||||
, " YTD Lifetime"
|
, " YTD Lifetime"
|
||||||
, " Games played 2 9"
|
, " Games played 2 9"
|
||||||
|
|
Loading…
Reference in New Issue
Block a user