Skip to content

Commit f4295f9

Browse files
committed
more tests
1 parent 9e9334b commit f4295f9

File tree

2 files changed

+31
-0
lines changed

2 files changed

+31
-0
lines changed

test/test1.expected

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -510,6 +510,17 @@ root
510510
│ │ 10│20 │
511511
│ │ │
512512
└─────┴──────────────────────────┘
513+
┌──────────────────────┬──────────────────────────────────────────────────────────────┬───────────────────────────────────────────────────┬────────────┬────────────┬─────────────────┐
514+
│subject │explanation │github │contributors│dependencies│expected reaction│
515+
├──────────────────────┼──────────────────────────────────────────────────────────────┼───────────────────────────────────────────────────┼────────────┼────────────┼─────────────────┤
516+
│announce: printbox 0.3│┌────────────────────────────────────────────────────────────┐│https://github.com/c-cube/printbox/releases/tag/0.3│Simon │├─mandatory │🎉 │
517+
│ ││PrintBox is a library for rendering nested tables, ││ ├────────────┤│ ├─dune │ │
518+
│ ││ trees, and similar structures in monospace text or HTML.││ │Guillaume ││ └─bytes │ │
519+
│ │└────────────────────────────────────────────────────────────┘│ ├────────────┤└─optional │ │
520+
│ │ │ │Matt │ ├─uutf │ │
521+
│ │ │ │ │ ├─uucp │ │
522+
│ │ │ │ │ └─tyxml │ │
523+
└──────────────────────┴──────────────────────────────────────────────────────────────┴───────────────────────────────────────────────────┴────────────┴────────────┴─────────────────┘
513524
┌────────────────────────────────────┐
514525
│nice unicode! 💪 │
515526
├────────────────────────────────────┤
@@ -528,3 +539,8 @@ root
528539
││ │└─────────────────┘││
529540
│└──────────────┴───────────────────┘│
530541
└────────────────────────────────────┘
542+
┌─────────────────────────────────┐
543+
│ab │
544+
│cd no color here │
545+
│hello world color me (but not me)│
546+
└─────────────────────────────────┘

test/test1.ml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,9 @@ let b =
9696
("expected reaction", text "🎉");
9797
]
9898

99+
(* announcefor 0.3 *)
100+
let () = print_endline @@ PrintBox_text.to_string b
101+
99102
module Unicode = struct
100103
let b =
101104
B.(frame @@ vlist [text "nice unicode! 💪"; frame @@
@@ -107,3 +110,15 @@ module Unicode = struct
107110

108111
let () = print_endline @@ PrintBox_text.to_string b
109112
end
113+
114+
module Rich_text_ = struct
115+
let b =
116+
B.(frame @@ rich_text @@ Rich_text.(lines [
117+
cat [with_style Style.(bg_color Cyan) (s "ab\ncd"); s " no color here"];
118+
cat [s "hello"; space; s "world";
119+
with_style Style.(fg_color Green) (s " color me"); s " (but not me)"];
120+
]));;
121+
122+
let () = print_endline @@ PrintBox_text.to_string b
123+
124+
end

0 commit comments

Comments
 (0)