HORIZON HASKELLDocslts/ghc-9.14.x45dd5372026-10-11Search names, modules, packages, or :: a typeCtrl K

GHC 9.14.1 · lts/ghc-9.14.x · 45dd537 · 2026-10-11

Modulesandwich-0.3.1.0Haskell2010

Test.Sandwich.Formatters.TerminalUI

  • 2 types
  • 11 values
  • Packagesandwich-0.3.1.0
  • Exports13
  • LanguageHaskell2010
  • LicenceBSD-3-Clause
  • SourceTypes.hs

The terminal UI formatter produces an interactive UI for running tests and inspecting their results.

Options

9 declarations
valueterminalUIDefaultEditor :: TerminalUIFormatter -> Maybe String
#

Default value to use for the EDITOR environment variable when one is not provided. If Nothing and EDITOR can't be found, edit commands will do nothing.

Here are some recommended values, depending on your preferred editor:

  • Emacs: export EDITOR="emacsclient --eval '(progn (find-file FILE) (goto-line LINE) (forward-char (- COLUMN 1)) (recenter))'"

  • Terminal Emacs: export EDITOR="emacsclient -nw --eval '(progn (find-file FILE) (goto-line LINE) (forward-char (- COLUMN 1)) (recenter))'"

  • Vim: export EDITOR="vim +LINE"

valueterminalUIOpenInEditor
  1. :: TerminalUIFormatter
  2. -> Maybe String
  3. -> Text -> IO ()
  4. -> SrcLoc
  5. -> IO ()
#

Callback to open a source location in your editor. By default, finds the command in the EDITOR environment variable and invokes it with the strings LINE, COLUMN, and FILE replaced with the line number, column, and file path. If FILE is not found in the string, it will be appended to the command after a space. It's also passed a debug callback that accepts a Text; messages logged with this function will go into the formatter logs.

valueterminalUIDebugSocket :: TerminalUIFormatter -> Bool
#

If True, create a Unix socket at <test-root>/tui-debug.sock for debug output. Connect with nc -U <path> to receive line-oriented debug events about the TUI event loop.

Auxiliary types

2 declarations

Util

1 declaration

Orphan instances

1 instance