feat(display): add methods to display

- Add `indent`, `faint`, and `underline` methods to `display`
- Add tests for the above
This commit is contained in:
Chris Lane
2020-11-27 13:40:24 -05:00
parent 367673d5d9
commit aa16f68620
6 changed files with 72 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
package display
import (
"testing"
)
// TestFaint asserts that Faint applies faint formatting
func TestFaint(t *testing.T) {
want := "\033[2mfoo\033[0m"
got := Faint("foo")
if want != got {
t.Errorf("failed to faint: want: %s, got: %s", want, got)
}
}