summaryrefslogtreecommitdiff
path: root/tests/suite/layout/measure.typ
diff options
context:
space:
mode:
Diffstat (limited to 'tests/suite/layout/measure.typ')
-rw-r--r--tests/suite/layout/measure.typ9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/suite/layout/measure.typ b/tests/suite/layout/measure.typ
new file mode 100644
index 00000000..5f82e915
--- /dev/null
+++ b/tests/suite/layout/measure.typ
@@ -0,0 +1,9 @@
+--- measure ---
+// Test `measure`.
+#let f(lo, hi) = context {
+ let h = measure[Hello].height
+ assert(h > lo)
+ assert(h < hi)
+}
+#text(10pt, f(6pt, 8pt))
+#text(20pt, f(13pt, 14pt))