@hackage hspec-junit-formatter1.0.2.1

A JUnit XML runner/formatter for hspec

hspec-junit-formatter

A JUnit XML runner/formatter for hspec.

Usage

import Test.Hspec
import Test.Hspec.Core.Runner (defaultConfig, hspecWith)
import Test.Hspec.JUnit

main :: IO ()
main = do
  let
    junitConfig = setJUnitConfigOutputDirectory "/tmp" $ defaultJUnitConfig "my-tests"
    hspecConfig = configWithJUnit junitConfig defaultConfig

  hspecWith hspecConfig spec

spec :: Spec
spec = describe "Addition" $ do
  it "adds" $ do
    2 + 2 `shouldBe` (4 :: Int)

LICENSE