summaryrefslogtreecommitdiff
path: root/tests/typ/layout
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2022-05-27 14:20:05 +0200
committerLaurenz <laurmaedje@gmail.com>2022-05-27 14:20:05 +0200
commit736289b064c53c215249aad70b3a6a96e79b6021 (patch)
tree6021129a25de18caa18469c946936f99bd7cb659 /tests/typ/layout
parentae68a15a46c3a9fce4db7bfbf129ee103dd4c30d (diff)
Ensure me is always contained in all
Diffstat (limited to 'tests/typ/layout')
-rw-r--r--tests/typ/layout/locate-group.typ19
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/typ/layout/locate-group.typ b/tests/typ/layout/locate-group.typ
index 49d4e335..5c022f5a 100644
--- a/tests/typ/layout/locate-group.typ
+++ b/tests/typ/layout/locate-group.typ
@@ -41,3 +41,22 @@
))}
As shown in #cite("abc") and #cite("def") and #cite("abc") ...
+
+---
+// Test that `all` contains `me`.
+// Ref: false
+#show it: heading as group("headings").entry(
+ (me, all) => {
+ let last
+ for prev in all {
+ last = prev
+ if prev.index == me.index {
+ break
+ }
+ }
+ assert(last == me)
+ }
+)
+
+= A
+== B