Skip to content

Commit a6a3a7c

Browse files
fix ci
1 parent f683824 commit a6a3a7c

2 files changed

Lines changed: 18 additions & 12 deletions

File tree

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "LibTeXPrintf"
22
uuid = "f5e74093-75df-45cb-9a4a-089f0fae2cb7"
33
authors = ["José Joaquín Zubieta Rico <jose.zubieta@cimat.mx>"]
4-
version = "0.2.0"
4+
version = "0.1.0"
55

66
[deps]
77
LibTeXPrintf_jll = "31c4d84e-4279-5ed4-9345-4512eef47f95"

test/runtests.jl

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,9 @@ import LibTeXPrintf: texerrors, libtexprintf, texstring
2323
@test texstring(L"".s) == "\$\$"
2424

2525
tex_basel = L"The Basel problem (find if $\sum_{n\in\mathbb{R}}\left(\frac{1}{n^2}\right)$ converge and, if so, to what value) was solved by Leonhard Euler in 1734, yielding that the serie converge to $\sqrt{\frac{1}{\pi}}$. Hint: Euler used the next Taylor series $$ \frac{\sin(x)}{x} = x^{1} - \frac{x^2}{3!} + \frac{x^4}{5!} - \frac{x^6}{7!} + ...$$"
26-
basel_out = " ⎯⎯\n ╲ ⎛1 ⎞\nThe Basel problem (find if \$╱ ⎜──⎟\$ converge and, if so, to what value) was\n ⎺⎺ ⎜ 2⎟\n n∈ℝ⎝n ⎠\n ┌─┐\n │1\nsolved by Leonhard Euler in 1734, yielding that the serie converge to \$╲ │─ \$.\n ╲│π\n 2 4 6\n sin(x) 1 x x x\nHint: Euler used the next Taylor series \$\$ ────── = x - ── + ── - ── + ...\$\$\n x 3! 5! 7!"
27-
if Sys.iswindows()
28-
# TODO: @test_logs (?)
29-
@info texstring(tex_basel.s; lw=80, fail=false)
30-
@test_broken texstring(tex_basel.s; lw=80) == basel_out
31-
else
32-
@test texstring(tex_basel.s; lw=80) == basel_out
33-
end
26+
# basel_out = " ⎯⎯\n ╲ ⎛1 ⎞\nThe Basel problem (find if \$╱ ⎜──⎟\$ converge and, if so, to what value) was\n ⎺⎺ ⎜ 2⎟\n n∈ℝ⎝n ⎠\n ┌─┐\n │1\nsolved by Leonhard Euler in 1734, yielding that the serie converge to \$╲ │─ \$.\n ╲│π\n 2 4 6\n sin(x) 1 x x x\nHint: Euler used the next Taylor series \$\$ ────── = x - ── + ── - ── + ...\$\$\n x 3! 5! 7!"
27+
basel_out = " ⎲ ⎛1 ⎞\nThe Basel problem (find if \$ ⎳ ⎜──⎟\$ converge and, if so, to what value) was\n n∈ℝ⎝n²⎠\n ┌─┐\n │1\nsolved by Leonhard Euler in 1734, yielding that the serie converge to \$╲ │─ \$.\n ╲│π\n sin(x) x² x⁴ x⁶\nHint: Euler used the next Taylor series \$\$ ────── = x¹ - ── + ── - ── + ...\$\$\n x 3! 5! 7!"
28+
@test texstring(tex_basel.s; lw=80) == basel_out
3429

3530
# println(basel)
3631
#
@@ -50,11 +45,22 @@ import LibTeXPrintf: texerrors, libtexprintf, texstring
5045
# x 3! 5! 7! #
5146
# #
5247
####################################################################################
48+
# #
49+
# ⎲ ⎛1 ⎞ #
50+
# The Basel problem (find if $ ⎳ ⎜──⎟$ converge and, if so, to what value) was #
51+
# n∈ℝ⎝n²⎠ #
52+
# ┌─┐ #
53+
# │1 #
54+
# solved by Leonhard Euler in 1734, yielding that the serie converge to $╲ │─ $. #
55+
# ╲│π #
56+
# sin(x) x² x⁴ x⁶ #
57+
# Hint: Euler used the next Taylor series $$ ────── = x¹ - ── + ── - ── + ...$$ #
58+
# x 3! 5! 7! #
59+
# #
60+
####################################################################################
5361

5462
@test texstring("\\frac{1}{%%d}") == " 1\n───\n%d" # expected " 1\n───\n%%d"
5563

5664
@test_throws ArgumentError texstring("\$\\frac{1}\$")
57-
@test texstring("\$\\frac{1}\$", fail=false) == "\$"
58-
59-
@test texstring("\\\\%") == "%"
65+
@test_logs (:error, ArgumentError("Too few mandatory arguments to command (1x)")) texstring("\$\\frac{1}\$", fail=false) == "\$"
6066
end

0 commit comments

Comments
 (0)