diff --git a/MANIFEST b/MANIFEST index ca3e007eb8..49ed46e4d0 100644 --- a/MANIFEST +++ b/MANIFEST @@ -983,6 +983,12 @@ t/daemon/api/port.xml t/daemon/citations.tex t/daemon/complex/exhaustive.spec t/daemon/complex/exhaustive.xml +t/daemon/complex/testlocks.spec +t/daemon/complex/testlocks.tex +t/daemon/complex/testlocks.xml +t/daemon/complex/testlocks.sty.ltxml +t/daemon/complex/testlocks-a.sty +t/daemon/complex/testlocks-b.sty.ltxml t/daemon/document.tex t/daemon/fatal_100.tex t/daemon/fatal_misdefined.tex diff --git a/t/daemon/complex/testlocks-a.sty b/t/daemon/complex/testlocks-a.sty new file mode 100644 index 0000000000..a0352d4aac --- /dev/null +++ b/t/daemon/complex/testlocks-a.sty @@ -0,0 +1,4 @@ + +% Ignored attempt to redefine \fooC +\def\fooC{testlocks-a FOO-C} +\RequirePackage{testlocks-b}; diff --git a/t/daemon/complex/testlocks-b.sty.ltxml b/t/daemon/complex/testlocks-b.sty.ltxml new file mode 100644 index 0000000000..57d446bba7 --- /dev/null +++ b/t/daemon/complex/testlocks-b.sty.ltxml @@ -0,0 +1,12 @@ +package LaTeXML::Package::Pool; +use strict; +use warnings; +use LaTeXML::Package; + +# RE-defintions (allowed) +DefMacro('\fooD', "testlocks-b FOO-D", locked => 1); + +# Definition, BUT will be RE-defined by testlocks.sty +DefMacro('\fooE', "testlocks-b FOO-E", locked => 1); + +1; diff --git a/t/daemon/complex/testlocks.spec b/t/daemon/complex/testlocks.spec new file mode 100644 index 0000000000..4e0c745dc0 --- /dev/null +++ b/t/daemon/complex/testlocks.spec @@ -0,0 +1,3 @@ +preload = testlocks.sty +source = testlocks.tex +format = xml diff --git a/t/daemon/complex/testlocks.sty.ltxml b/t/daemon/complex/testlocks.sty.ltxml new file mode 100644 index 0000000000..776abfc4f5 --- /dev/null +++ b/t/daemon/complex/testlocks.sty.ltxml @@ -0,0 +1,16 @@ +package LaTeXML::Package::Pool; +use strict; +use warnings; +use LaTeXML::Package; + +DefMacro('\fooA', "testlocks FOO-A", locked => 1); +DefMacro('\fooB', "testlocks FOO-B", locked => 1); +DefMacro('\fooC', "testlocks FOO-C", locked => 1); +DefMacro('\fooD', "testlocks FOO-D", locked => 1); + +InputDefinitions("testlocks-a", type => 'sty', noltxml => 1); + +# This gets defined in testlocks-b.sty.ltxml, input from testlocks-a.sty +DefMacro('\fooE', "testlocks FOO-E", locked => 1); + +1; diff --git a/t/daemon/complex/testlocks.tex b/t/daemon/complex/testlocks.tex new file mode 100644 index 0000000000..f9ba30a531 --- /dev/null +++ b/t/daemon/complex/testlocks.tex @@ -0,0 +1,16 @@ +\documentclass{article} +%\usepackage{testlocks} +% Ignored re-definition +\def\fooB{Locak FOO-B} +\begin{document} +testlocks FOO-A:\fooA + +testlocks FOO-B:\fooB + +testlocks FOO-C:\fooC + +testlocks-b FOO-D:\fooD + +testlocks FOO-E:\fooE + +\end{document} \ No newline at end of file diff --git a/t/daemon/complex/testlocks.xml b/t/daemon/complex/testlocks.xml new file mode 100644 index 0000000000..fcd3e1f258 --- /dev/null +++ b/t/daemon/complex/testlocks.xml @@ -0,0 +1,23 @@ + + + + + + + + +

testlocks FOO-A:testlocks FOO-A

+
+ +

testlocks FOO-B:testlocks FOO-B

+
+ +

testlocks FOO-C:testlocks FOO-C

+
+ +

testlocks-b FOO-D:testlocks-b FOO-D

+
+ +

testlocks FOO-E:testlocks FOO-E

+
+