-
Notifications
You must be signed in to change notification settings - Fork 60
Expand file tree
/
Copy pathfigure_test.go
More file actions
27 lines (24 loc) · 862 Bytes
/
figure_test.go
File metadata and controls
27 lines (24 loc) · 862 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
package figure
import (
"fmt"
)
func ExampleAlphabet() {
myFigure := NewFigure("Hello world", "alphabet", true)
fmt.Println(myFigure)
// Output:
// H H l l l d
// H H l l l d
// HHHH eee l l ooo w w ooo rrr l ddd
// H H e e l l o o w w w o o r l d d
// H H ee l l ooo w w ooo r l ddd
}
func ExampleDefault() {
myFigure := NewFigure("Hello world", "", true)
fmt.Println(myFigure)
// Output:
// _ _ _ _ _ _
// | | | | ___ | | | | ___ __ __ ___ _ __ | | __| |
// | |_| | / _ \ | | | | / _ \ \ \ /\ / / / _ \ | '__| | | / _` |
// | _ | | __/ | | | | | (_) | \ V V / | (_) | | | | | | (_| |
// |_| |_| \___| |_| |_| \___/ \_/\_/ \___/ |_| |_| \__,_|
}