diff options
| author | Laurenz <laurmaedje@gmail.com> | 2022-10-04 13:42:49 +0200 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2022-10-04 13:45:16 +0200 |
| commit | 5a8534a395b500a25cbc46ee15ec031c8231de59 (patch) | |
| tree | a525c447c3243fe315c7ed91923e158df131809b /tests | |
| parent | 7ef6cb31df0fe1ebec99b1077053a586a349f530 (diff) | |
Parse basic math syntax
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/typ/math/basic.typ | 10 | ||||
| -rw-r--r-- | tests/typeset.rs | 3 |
2 files changed, 4 insertions, 9 deletions
diff --git a/tests/typ/math/basic.typ b/tests/typ/math/basic.typ index 77d2e535..a1a9d32f 100644 --- a/tests/typ/math/basic.typ +++ b/tests/typ/math/basic.typ @@ -9,11 +9,11 @@ $ a^2 + b^2 = c^2 $ --- Prove by induction: -$ \sum_{k=0}^n k = \frac{n(n+1)}{2} $ +$ sum_(k=0)^n k = (n(n+1))/2 $ --- // Test that blackboard style looks nice. -$ f: \mathbb{N} \rightarrow \mathbb{R} $ +$ f: NN arrow RR $ --- #set math(family: "IBM Plex Sans") @@ -22,9 +22,5 @@ $ f: \mathbb{N} \rightarrow \mathbb{R} $ $a$ --- -// Error: 1-10 expected '}' found EOF -$\sqrt{x$ - ---- -// Error: 2:1 expected dollar sign +// Error: 1:3 expected dollar sign $a diff --git a/tests/typeset.rs b/tests/typeset.rs index b6cb217d..0eb3fc45 100644 --- a/tests/typeset.rs +++ b/tests/typeset.rs @@ -435,8 +435,7 @@ fn test_part( .filter(|error| error.span.source() == id) .map(|error| { let range = world.source(error.span.source()).range(error.span); - let msg = error.message.replace("\\", "/"); - (range, msg) + (range, error.message.to_string()) }) .collect(); |
