diff --git a/base/testfiles-lthooks/helpers/lthooks-show.sty b/base/testfiles-lthooks/helpers/lthooks-show.sty index 319a8df32..2fe08d150 100644 --- a/base/testfiles-lthooks/helpers/lthooks-show.sty +++ b/base/testfiles-lthooks/helpers/lthooks-show.sty @@ -1,5 +1,100 @@ % This is a library of commands used by various `lthooks*.lvt` +\ExplSyntaxOn +\tl_new:N \l__TESTHookShow_tl + +\IncludeInRelease{2023-06-01}{\WithArgs}{With arguments} + \cs_new:Npn \TESTHookWithArgs:Nnn #1 #2 #3 + % #1 the local tl variable holding the result + % #2 the template + % #3 the number of arguments + { + \tl_clear:N #1 + \int_step_inline:nn { #3 } { \tl_put_right:Nn #1 { #2 } } + } + \def\TESTBlockHookCmdWithArgs#1#2#3{ + % run at the top level + % #1: the title of the block + % #2: the csname of the command + \BEGINTEST{Command:~#1} + \DebugShowHookCmd{#2} + \TESTHookWithArgs:Nnn \l__TESTHookShow_tl { ######1/ } { #3 } + \exp_args:Nnx + \AddToHookWithArguments { cmd/#2/before } + { \exp_not:N \TYPE { <#2~BEFORE:~/\exp_not:V \l__TESTHookShow_tl> } } + \exp_args:Nnx + \AddToHookWithArguments { cmd/#2/after } + { \exp_not:N \TYPE { <#2~AFTER :~/\exp_not:V \l__TESTHookShow_tl> } } + \DebugShowHookCmd{#2} + \ENDTEST + } + \def\TESTBlockHookWithArgs#1#2#3{ + % run at the top level + % #1: the title of the block + % #2: the name of the hook + % #3: the number of arguments + % Not in the 2020-10-01 release + \BEGINTEST{#1} + \def\TEST{ + \TESTHookWithArgs:Nnn \l__TESTHookShow_tl { { arg_####1 } } { #3 } + \TYPE{\token_to_str:N \UseHookWithArguments {#2} {#3} \l__TESTHookShow_tl =>} + \exp_last_unbraced:Nno + \use:n { \UseHookWithArguments {#2} {#3} } \l__TESTHookShow_tl + \ShowHook{#2} + } + \BEGINTEST{Undeclared~#2} + \TEST + \ENDTEST + \BEGINTEST{#2~+~TOP-LEVEL} + \TESTHookWithArgs:Nnn \l__TESTHookShow_tl { arg~######1 / } { #3 } + \exp_args:Nnx + \use:n { \AddToHookWithArguments { #2 } } + { \exp_not:N \TYPE { <#2~TOP-LEVEL:~/\exp_not:V \l__TESTHookShow_tl> } } + \TEST + \ENDTEST + \BEGINTEST{#2~+~A~LABEL} + \TESTHookWithArgs:Nnn \l__TESTHookShow_tl { arg~######1 / } { #3 } + \exp_args:Nnx + \use:n { \AddToHookWithArguments { #2 }[A~LABEL] } + { \exp_not:N \TYPE { <#2~A~CODE:~/\exp_not:V \l__TESTHookShow_tl> } } + \TEST + \ENDTEST + \BEGINTEST{#2~+~B~LABEL} + \TESTHookWithArgs:Nnn \l__TESTHookShow_tl { arg~######1 / } { #3 } + \exp_args:Nnx + \use:n { \AddToHookWithArguments { #2 }[B~LABEL] } + { \exp_not:N \TYPE { <#2~B~CODE:~/\exp_not:V \l__TESTHookShow_tl> } } + \TEST + \ENDTEST + \BEGINTEST{#2~+~C~LABEL} + \TESTHookWithArgs:Nnn \l__TESTHookShow_tl { arg~######1 / } { #3 } + \exp_args:Nnx + \use:n { \AddToHookWithArguments { #2 }[C~LABEL] } + { \exp_not:N \TYPE { <#2~C~CODE:~/\exp_not:V \l__TESTHookShow_tl> } } + \TEST + \ENDTEST + \BEGINTEST{#2~+~NEXT} + \TESTHookWithArgs:Nnn \l__TESTHookShow_tl { arg~######1 / } { #3 } + \exp_args:Nnx + \use:n { \AddToHookNextWithArguments { #2 } } + { \exp_not:N \TYPE { <#2~NEXT-ONLY~CODE:~/\exp_not:V \l__TESTHookShow_tl> } } + \ShowHook{#2} + \TEST + \ENDTEST + \BEGINTEST{#2~+~C~LABEL~<~A~LABEL} + \DeclareHookRule{#2}{C~LABEL}{before}{A~LABEL} + \TEST + \ENDTEST + \BEGINTEST{#2~+~DEFAULT:~B~LABEL~>~C~LABEL} + \DeclareDefaultHookRule{B~LABEL}{after}{C~LABEL} + \TEST + \ENDTEST + \ENDTEST + } +\EndIncludeInRelease +\ExplSyntaxOff +% + \IncludeInRelease{2020-10-01}{\TESTBlockHook}{Message} \def\DebugShowHookEnv#1{ @@ -74,7 +169,7 @@ \BEGINTEST{Undeclared #2} \TEST \ENDTEST - \BEGINTEST{#2 + TOP LEVEL} + \BEGINTEST{#2 + TOP-LEVEL} \AddToHook{#2}{\TYPE{<#2 TOP-LEVEL>}} \TEST \ENDTEST diff --git a/base/testfiles-lthooks/lthooks-show-2020-10-01.tlg b/base/testfiles-lthooks/lthooks-show-2020-10-01.tlg index 2119e09a4..0ee179e11 100644 --- a/base/testfiles-lthooks/lthooks-show-2020-10-01.tlg +++ b/base/testfiles-lthooks/lthooks-show-2020-10-01.tlg @@ -319,7 +319,7 @@ TEST 10: Undeclared UNDECLARED HOOK l. ... {UNDECLARED HOOK} ============================================================ ============================================================ -TEST 11: UNDECLARED HOOK + TOP LEVEL +TEST 11: UNDECLARED HOOK + TOP-LEVEL ============================================================ -> The hook 'UNDECLARED HOOK': > The hook is not declared. @@ -483,7 +483,7 @@ TEST 19: Undeclared DECLARED HOOK l. ... {DECLARED HOOK} ============================================================ ============================================================ -TEST 20: DECLARED HOOK + TOP LEVEL +TEST 20: DECLARED HOOK + TOP-LEVEL ============================================================ -> The hook 'DECLARED HOOK': @@ -663,7 +663,7 @@ TEST 28: Undeclared DECLARED REVERSED l. ... {DECLARED REVERSED} ============================================================ ============================================================ -TEST 29: DECLARED REVERSED + TOP LEVEL +TEST 29: DECLARED REVERSED + TOP-LEVEL ============================================================ -> The hook 'DECLARED REVERSED': diff --git a/base/testfiles-lthooks/lthooks-show-2023-06-01.lvt b/base/testfiles-lthooks/lthooks-show-2023-06-01.lvt new file mode 100644 index 000000000..b4f63ee0d --- /dev/null +++ b/base/testfiles-lthooks/lthooks-show-2023-06-01.lvt @@ -0,0 +1,121 @@ +% Frozen to the 2023-06-01 release. + +\input{regression-test} +\RequirePackage[2023-06-01]{latexrelease} +\TYPE{********* RequirePackage[2023-06-01]{latexrelease}} +\RequirePackage{./lthooks-show} + +\ExplSyntaxOn +\debug_on:n { check-declarations , deprecation } +\ExplSyntaxOff + +\documentclass{article} + +% There are many different hook profiles. + +\START + +\TESTBlockHookEnv + {Undefined environment envA} + {envA} +\NewDocumentEnvironment + {envA}{} + {\TYPE{}} + {\TYPE{}} +\begin{envA}\TYPE{}\end{envA} + +\NewDocumentEnvironment + {envB}{} + {\TYPE{}} + {\TYPE{}} +\TESTBlockHookEnv + {Defined environment envB} + {envB} +\begin{envB}\TYPE{}\end{envB} + +\TESTBlockHookCmd + {Undefined command with no arguments} + {cmdA} +\NewDocumentCommand\cmdA{}{\TYPE{}} +\cmdA + +\NewDocumentCommand\cmdB{}{\TYPE{}} +\TESTBlockHookCmd + {Defined command with no arguments} + {cmdB} +\cmdA + +\TESTBlockHookCmdWithArgs + {Undefined with two arguments} + {cmdTwoArgsA} + {2} +\NewDocumentCommand\cmdTwoArgsA{mm}{\TYPE{}} +\cmdTwoArgsA{argA 1}{argA 2} + +\NewDocumentCommand\cmdTwoArgsB{mm}{\TYPE{}} +\TESTBlockHookCmdWithArgs + {Defined with two arguments} + {cmdTwoArgsB} + {2} +\cmdTwoArgsB{argB 1}{argB 2} + +\TESTBlockHookCustomGeneric + {CUSTOM GENERIC HOOK} + {CUSTOM GENERIC HOOK} + +\TESTBlockHook + {OTHER HOOK: Undeclared} + {UNDECLARED HOOK} + +\NewHook{DECLARED HOOK} + +\TESTBlockHook + {OTHER HOOK: declared} + {DECLARED HOOK} + +\NewReversedHook{DECLARED REVERSED} + +\TESTBlockHook + {OTHER HOOK: declared reversed} + {DECLARED REVERSED} + +\NewHookWithArguments + {WITH TWO ARGUMENTS} + {2} + +\TESTBlockHookWithArgs + {OTHER HOOK: with two arguments} + {WITH TWO ARGUMENTS} + {2} + +\NewReversedHookWithArguments + {REVERSED WITH TWO ARGUMENTS} + {2} + +\TESTBlockHookWithArgs + {OTHER HOOK: reversed with two arguments} + {REVERSED WITH TWO ARGUMENTS} + {2} + +\OMIT +\begin{document} +\TIMO + +\BEGINTEST{After \begin{document}} + + \BEGINTEST{Commands} + \cmdA + \SEPARATOR + \cmdB + \SEPARATOR + \cmdTwoArgsA{argA 1}{argA 2} + \SEPARATOR + \cmdTwoArgsB{argB 1}{argB 2} + \ENDTEST + +\ENDTEST + + +\TYPE{!!!! If this test changes the documentation needs updating !!!!} + +\END diff --git a/base/testfiles-lthooks/lthooks-show-2023-06-01.tlg b/base/testfiles-lthooks/lthooks-show-2023-06-01.tlg new file mode 100644 index 000000000..ec3fc337a --- /dev/null +++ b/base/testfiles-lthooks/lthooks-show-2023-06-01.tlg @@ -0,0 +1,1316 @@ +This is a generated file for the l3build validation system. +Don't change this file in any respect. +============================================================ +TEST 1: Environment: envA +============================================================ +-> The generic hook 'env/envA/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {envA} +-> The generic hook 'env/envA/begin': +> The hook is not declared. +> The hook is empty. + } +l. ... {envA} +-> The generic hook 'env/envA/end': +> The hook is not declared. +> The hook is empty. + } +l. ... {envA} +-> The generic hook 'env/envA/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {envA} +-> The generic hook 'env/envA/before': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envA} +-> The generic hook 'env/envA/begin': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envA} +-> The generic hook 'env/envA/end': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envA} +-> The generic hook 'env/envA/after': +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {envA} +============================================================ + + + + + + + +============================================================ +TEST 2: Environment: envB +============================================================ +-> The generic hook 'env/envB/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {envB} +-> The generic hook 'env/envB/begin': +> The hook is not declared. +> The hook is empty. + } +l. ... {envB} +-> The generic hook 'env/envB/end': +> The hook is not declared. +> The hook is empty. + } +l. ... {envB} +-> The generic hook 'env/envB/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {envB} +-> The generic hook 'env/envB/before': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envB} +-> The generic hook 'env/envB/begin': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envB} +-> The generic hook 'env/envB/end': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envB} +-> The generic hook 'env/envB/after': +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {envB} +============================================================ + + + + + + + +============================================================ +TEST 3: Command: Undefined command with no arguments +============================================================ +-> The generic hook 'cmd/cmdA/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {cmdA} +-> The generic hook 'cmd/cmdA/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {cmdA} +-> The generic hook 'cmd/cmdA/before' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {cmdA} +-> The generic hook 'cmd/cmdA/after' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {cmdA} +============================================================ + +============================================================ +TEST 4: Command: Defined command with no arguments +============================================================ +-> The generic hook 'cmd/cmdB/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {cmdB} +-> The generic hook 'cmd/cmdB/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {cmdB} +-> The generic hook 'cmd/cmdB/before' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {cmdB} +-> The generic hook 'cmd/cmdB/after' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {cmdB} +============================================================ + +============================================================ +TEST 5: Command: Undefined with two arguments +============================================================ +-> The generic hook 'cmd/cmdTwoArgsA/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsA/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsA/before' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsA/after' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {2} +============================================================ + +============================================================ +TEST 6: Command: Defined with two arguments +============================================================ +-> The generic hook 'cmd/cmdTwoArgsB/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsB/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsB/before' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsB/after' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {2} +============================================================ + +============================================================ +TEST 7: Custom generic hook: CUSTOM GENERIC HOOK +============================================================ +============================================================ +TEST 8: Raw: CUSTOM GENERIC HOOK +============================================================ +-> The hook 'CUSTOM GENERIC HOOK': +> The hook is not declared. +> Code chunks: +> LABEL -> \TYPE {} +> Document-level (top-level) code: +> --- +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {CUSTOM GENERIC HOOK} +============================================================ +============================================================ +TEST 9: Activated: CUSTOM GENERIC HOOK +============================================================ + +-> The hook 'CUSTOM GENERIC HOOK': +> Code chunks: +> LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> --- +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> LABEL. + } +l. ... {CUSTOM GENERIC HOOK} +============================================================ +============================================================ +TEST 10: Disabled: CUSTOM GENERIC HOOK +============================================================ +-> The hook 'CUSTOM GENERIC HOOK': +> The hook is not declared. +> The hook is disabled. +> Code chunks: +> LABEL -> \TYPE {} +> Document-level (top-level) code: +> --- +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is disabled. + } +l. ... {CUSTOM GENERIC HOOK} +============================================================ +============================================================ +============================================================ +TEST 11: OTHER HOOK: Undeclared +============================================================ +============================================================ +TEST 12: Undeclared UNDECLARED HOOK +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> The hook is empty. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 13: UNDECLARED HOOK + TOP-LEVEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> --- +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 14: UNDECLARED HOOK + A LABEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 15: UNDECLARED HOOK + B LABEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 16: UNDECLARED HOOK + C LABEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 17: UNDECLARED HOOK + NEXT +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 18: UNDECLARED HOOK + C LABEL < A LABEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|A LABEL with relation < +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 19: UNDECLARED HOOK + DEFAULT: B LABEL > C LABEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +============================================================ +TEST 20: OTHER HOOK: declared +============================================================ +============================================================ +TEST 21: Undeclared DECLARED HOOK +============================================================ +-> The hook 'DECLARED HOOK': +> The hook is empty. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 22: DECLARED HOOK + TOP-LEVEL +============================================================ + +-> The hook 'DECLARED HOOK': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 23: DECLARED HOOK + A LABEL +============================================================ + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> A LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 24: DECLARED HOOK + B LABEL +============================================================ + + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> A LABEL, B LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 25: DECLARED HOOK + C LABEL +============================================================ + + + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 26: DECLARED HOOK + NEXT +============================================================ +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {DECLARED HOOK} + + + + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 27: DECLARED HOOK + C LABEL < A LABEL +============================================================ + + + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> C LABEL, A LABEL, B LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 28: DECLARED HOOK + DEFAULT: B LABEL > C LABEL +============================================================ + + + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> C LABEL, A LABEL, B LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +============================================================ +TEST 29: OTHER HOOK: declared reversed +============================================================ +============================================================ +TEST 30: Undeclared DECLARED REVERSED +============================================================ +-> The hook 'DECLARED REVERSED': +> The hook is empty. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 31: DECLARED REVERSED + TOP-LEVEL +============================================================ + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 32: DECLARED REVERSED + A LABEL +============================================================ + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 33: DECLARED REVERSED + B LABEL +============================================================ + + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> B LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 34: DECLARED REVERSED + C LABEL +============================================================ + + + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 35: DECLARED REVERSED + NEXT +============================================================ +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} + + + + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 36: DECLARED REVERSED + C LABEL < A LABEL +============================================================ + + + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 37: DECLARED REVERSED + DEFAULT: B LABEL > C LABEL +============================================================ + + + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +============================================================ +TEST 38: OTHER HOOK: with two arguments +============================================================ +============================================================ +TEST 39: Undeclared WITH TWO ARGUMENTS +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> The hook is empty. + } +l. ... {2} +============================================================ +============================================================ +TEST 40: WITH TWO ARGUMENTS + TOP-LEVEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {2} +============================================================ +============================================================ +TEST 41: WITH TWO ARGUMENTS + A LABEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 42: WITH TWO ARGUMENTS + B LABEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> A LABEL, B LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 43: WITH TWO ARGUMENTS + C LABEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 44: WITH TWO ARGUMENTS + NEXT +============================================================ +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {2} +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 45: WITH TWO ARGUMENTS + C LABEL < A LABEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> C LABEL, A LABEL, B LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 46: WITH TWO ARGUMENTS + DEFAULT: B LABEL > C LABEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> C LABEL, A LABEL, B LABEL. + } +l. ... {2} +============================================================ +============================================================ +============================================================ +TEST 47: OTHER HOOK: reversed with two arguments +============================================================ +============================================================ +TEST 48: Undeclared REVERSED WITH TWO ARGUMENTS +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> The hook is empty. + } +l. ... {2} +============================================================ +============================================================ +TEST 49: REVERSED WITH TWO ARGUMENTS + TOP-LEVEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {2} +============================================================ +============================================================ +TEST 50: REVERSED WITH TWO ARGUMENTS + A LABEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 51: REVERSED WITH TWO ARGUMENTS + B LABEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> B LABEL, A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 52: REVERSED WITH TWO ARGUMENTS + C LABEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 53: REVERSED WITH TWO ARGUMENTS + NEXT +============================================================ +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {2} +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 54: REVERSED WITH TWO ARGUMENTS + C LABEL < A LABEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 55: REVERSED WITH TWO ARGUMENTS + DEFAULT: B LABEL > C LABEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {2} +============================================================ +============================================================ +============================================================ +TEST 56: After \begin {document} +============================================================ +============================================================ +TEST 57: Commands +============================================================ + + + +============================================================ + + + +============================================================ + + + +============================================================ + + + +============================================================ +============================================================ +!!!! If this test changes the documentation needs updating !!!! diff --git a/base/testfiles-lthooks/lthooks-show.lvt b/base/testfiles-lthooks/lthooks-show.lvt new file mode 100644 index 000000000..f5543f744 --- /dev/null +++ b/base/testfiles-lthooks/lthooks-show.lvt @@ -0,0 +1,121 @@ +% This corresponds to the latest release. +% Other `lthooks-show_????-??-??.lvt` files are frozen to +% the ????-??-?? release. + +\input{regression-test} +\RequirePackage{./lthooks-show} + +\ExplSyntaxOn +\debug_on:n { check-declarations , deprecation } +\ExplSyntaxOff + +\documentclass{article} + +% There are many different hook profiles. + +\START + +\TESTBlockHookEnv + {Undefined environment envA} + {envA} +\NewDocumentEnvironment + {envA}{} + {\TYPE{}} + {\TYPE{}} +\begin{envA}\TYPE{}\end{envA} + +\NewDocumentEnvironment + {envB}{} + {\TYPE{}} + {\TYPE{}} +\TESTBlockHookEnv + {Defined environment envB} + {envB} +\begin{envB}\TYPE{}\end{envB} + +\TESTBlockHookCmd + {Undefined command with no arguments} + {cmdA} +\NewDocumentCommand\cmdA{}{\TYPE{}} +\cmdA + +\NewDocumentCommand\cmdB{}{\TYPE{}} +\TESTBlockHookCmd + {Defined command with no arguments} + {cmdB} +\cmdA + +\TESTBlockHookCmdWithArgs + {Undefined with two arguments} + {cmdTwoArgsA} + {2} +\NewDocumentCommand\cmdTwoArgsA{mm}{\TYPE{}} +\cmdTwoArgsA{argA 1}{argA 2} + +\NewDocumentCommand\cmdTwoArgsB{mm}{\TYPE{}} +\TESTBlockHookCmdWithArgs + {Defined with two arguments} + {cmdTwoArgsB} + {2} +\cmdTwoArgsB{argB 1}{argB 2} + +\TESTBlockHookCustomGeneric + {CUSTOM GENERIC HOOK} + {CUSTOM GENERIC HOOK} + +\TESTBlockHook + {OTHER HOOK: Undeclared} + {UNDECLARED HOOK} + +\NewHook{DECLARED HOOK} + +\TESTBlockHook + {OTHER HOOK: declared} + {DECLARED HOOK} + +\NewReversedHook{DECLARED REVERSED} + +\TESTBlockHook + {OTHER HOOK: declared reversed} + {DECLARED REVERSED} + +\NewHookWithArguments + {WITH TWO ARGUMENTS} + {2} + +\TESTBlockHookWithArgs + {OTHER HOOK: with two arguments} + {WITH TWO ARGUMENTS} + {2} + +\NewReversedHookWithArguments + {REVERSED WITH TWO ARGUMENTS} + {2} + +\TESTBlockHookWithArgs + {OTHER HOOK: reversed with two arguments} + {REVERSED WITH TWO ARGUMENTS} + {2} + +\OMIT +\begin{document} +\TIMO + +\BEGINTEST{After \begin{document}} + + \BEGINTEST{Commands} + \cmdA + \SEPARATOR + \cmdB + \SEPARATOR + \cmdTwoArgsA{argA 1}{argA 2} + \SEPARATOR + \cmdTwoArgsB{argB 1}{argB 2} + \ENDTEST + +\ENDTEST + + +\TYPE{!!!! If this test changes the documentation needs updating !!!!} + +\END diff --git a/base/testfiles-lthooks/lthooks-show.tlg b/base/testfiles-lthooks/lthooks-show.tlg new file mode 100644 index 000000000..ec3fc337a --- /dev/null +++ b/base/testfiles-lthooks/lthooks-show.tlg @@ -0,0 +1,1316 @@ +This is a generated file for the l3build validation system. +Don't change this file in any respect. +============================================================ +TEST 1: Environment: envA +============================================================ +-> The generic hook 'env/envA/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {envA} +-> The generic hook 'env/envA/begin': +> The hook is not declared. +> The hook is empty. + } +l. ... {envA} +-> The generic hook 'env/envA/end': +> The hook is not declared. +> The hook is empty. + } +l. ... {envA} +-> The generic hook 'env/envA/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {envA} +-> The generic hook 'env/envA/before': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envA} +-> The generic hook 'env/envA/begin': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envA} +-> The generic hook 'env/envA/end': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envA} +-> The generic hook 'env/envA/after': +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {envA} +============================================================ + + + + + + + +============================================================ +TEST 2: Environment: envB +============================================================ +-> The generic hook 'env/envB/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {envB} +-> The generic hook 'env/envB/begin': +> The hook is not declared. +> The hook is empty. + } +l. ... {envB} +-> The generic hook 'env/envB/end': +> The hook is not declared. +> The hook is empty. + } +l. ... {envB} +-> The generic hook 'env/envB/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {envB} +-> The generic hook 'env/envB/before': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envB} +-> The generic hook 'env/envB/begin': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envB} +-> The generic hook 'env/envB/end': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {envB} +-> The generic hook 'env/envB/after': +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {envB} +============================================================ + + + + + + + +============================================================ +TEST 3: Command: Undefined command with no arguments +============================================================ +-> The generic hook 'cmd/cmdA/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {cmdA} +-> The generic hook 'cmd/cmdA/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {cmdA} +-> The generic hook 'cmd/cmdA/before' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {cmdA} +-> The generic hook 'cmd/cmdA/after' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {cmdA} +============================================================ + +============================================================ +TEST 4: Command: Defined command with no arguments +============================================================ +-> The generic hook 'cmd/cmdB/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {cmdB} +-> The generic hook 'cmd/cmdB/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {cmdB} +-> The generic hook 'cmd/cmdB/before' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {cmdB} +-> The generic hook 'cmd/cmdB/after' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {cmdB} +============================================================ + +============================================================ +TEST 5: Command: Undefined with two arguments +============================================================ +-> The generic hook 'cmd/cmdTwoArgsA/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsA/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsA/before' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsA/after' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {2} +============================================================ + +============================================================ +TEST 6: Command: Defined with two arguments +============================================================ +-> The generic hook 'cmd/cmdTwoArgsB/before': +> The hook is not declared. +> The hook is empty. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsB/after': +> The hook is not declared. +> The hook is empty. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsB/before' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {2} +-> The generic hook 'cmd/cmdTwoArgsB/after' (unknown arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {2} +============================================================ + +============================================================ +TEST 7: Custom generic hook: CUSTOM GENERIC HOOK +============================================================ +============================================================ +TEST 8: Raw: CUSTOM GENERIC HOOK +============================================================ +-> The hook 'CUSTOM GENERIC HOOK': +> The hook is not declared. +> Code chunks: +> LABEL -> \TYPE {} +> Document-level (top-level) code: +> --- +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {CUSTOM GENERIC HOOK} +============================================================ +============================================================ +TEST 9: Activated: CUSTOM GENERIC HOOK +============================================================ + +-> The hook 'CUSTOM GENERIC HOOK': +> Code chunks: +> LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> --- +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> LABEL. + } +l. ... {CUSTOM GENERIC HOOK} +============================================================ +============================================================ +TEST 10: Disabled: CUSTOM GENERIC HOOK +============================================================ +-> The hook 'CUSTOM GENERIC HOOK': +> The hook is not declared. +> The hook is disabled. +> Code chunks: +> LABEL -> \TYPE {} +> Document-level (top-level) code: +> --- +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is disabled. + } +l. ... {CUSTOM GENERIC HOOK} +============================================================ +============================================================ +============================================================ +TEST 11: OTHER HOOK: Undeclared +============================================================ +============================================================ +TEST 12: Undeclared UNDECLARED HOOK +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> The hook is empty. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 13: UNDECLARED HOOK + TOP-LEVEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> --- +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 14: UNDECLARED HOOK + A LABEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 15: UNDECLARED HOOK + B LABEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 16: UNDECLARED HOOK + C LABEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 17: UNDECLARED HOOK + NEXT +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> --- +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 18: UNDECLARED HOOK + C LABEL < A LABEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|A LABEL with relation < +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +TEST 19: UNDECLARED HOOK + DEFAULT: B LABEL > C LABEL +============================================================ +-> The hook 'UNDECLARED HOOK': +> The hook is not declared. +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code: +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order: +> Not set because the hook is undeclared. + } +l. ... {UNDECLARED HOOK} +============================================================ +============================================================ +============================================================ +TEST 20: OTHER HOOK: declared +============================================================ +============================================================ +TEST 21: Undeclared DECLARED HOOK +============================================================ +-> The hook 'DECLARED HOOK': +> The hook is empty. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 22: DECLARED HOOK + TOP-LEVEL +============================================================ + +-> The hook 'DECLARED HOOK': +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 23: DECLARED HOOK + A LABEL +============================================================ + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> A LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 24: DECLARED HOOK + B LABEL +============================================================ + + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> A LABEL, B LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 25: DECLARED HOOK + C LABEL +============================================================ + + + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 26: DECLARED HOOK + NEXT +============================================================ +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {DECLARED HOOK} + + + + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 27: DECLARED HOOK + C LABEL < A LABEL +============================================================ + + + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> C LABEL, A LABEL, B LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +TEST 28: DECLARED HOOK + DEFAULT: B LABEL > C LABEL +============================================================ + + + + +-> The hook 'DECLARED HOOK': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> C LABEL, A LABEL, B LABEL. + } +l. ... {DECLARED HOOK} +============================================================ +============================================================ +============================================================ +TEST 29: OTHER HOOK: declared reversed +============================================================ +============================================================ +TEST 30: Undeclared DECLARED REVERSED +============================================================ +-> The hook 'DECLARED REVERSED': +> The hook is empty. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 31: DECLARED REVERSED + TOP-LEVEL +============================================================ + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 32: DECLARED REVERSED + A LABEL +============================================================ + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 33: DECLARED REVERSED + B LABEL +============================================================ + + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> B LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 34: DECLARED REVERSED + C LABEL +============================================================ + + + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 35: DECLARED REVERSED + NEXT +============================================================ +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} + + + + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 36: DECLARED REVERSED + C LABEL < A LABEL +============================================================ + + + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +TEST 37: DECLARED REVERSED + DEFAULT: B LABEL > C LABEL +============================================================ + + + + +-> The hook 'DECLARED REVERSED': +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {DECLARED REVERSED} +============================================================ +============================================================ +============================================================ +TEST 38: OTHER HOOK: with two arguments +============================================================ +============================================================ +TEST 39: Undeclared WITH TWO ARGUMENTS +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> The hook is empty. + } +l. ... {2} +============================================================ +============================================================ +TEST 40: WITH TWO ARGUMENTS + TOP-LEVEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> ---. + } +l. ... {2} +============================================================ +============================================================ +TEST 41: WITH TWO ARGUMENTS + A LABEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 42: WITH TWO ARGUMENTS + B LABEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order: +> A LABEL, B LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 43: WITH TWO ARGUMENTS + C LABEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 44: WITH TWO ARGUMENTS + NEXT +============================================================ +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {2} +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> A LABEL, C LABEL, B LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 45: WITH TWO ARGUMENTS + C LABEL < A LABEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> C LABEL, A LABEL, B LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 46: WITH TWO ARGUMENTS + DEFAULT: B LABEL > C LABEL +============================================================ +\UseHookWithArguments{WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed last): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after applying rules): +> C LABEL, A LABEL, B LABEL. + } +l. ... {2} +============================================================ +============================================================ +============================================================ +TEST 47: OTHER HOOK: reversed with two arguments +============================================================ +============================================================ +TEST 48: Undeclared REVERSED WITH TWO ARGUMENTS +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> The hook is empty. + } +l. ... {2} +============================================================ +============================================================ +TEST 49: REVERSED WITH TWO ARGUMENTS + TOP-LEVEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> --- +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> ---. + } +l. ... {2} +============================================================ +============================================================ +TEST 50: REVERSED WITH TWO ARGUMENTS + A LABEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 51: REVERSED WITH TWO ARGUMENTS + B LABEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> --- +> Execution order (after reversal): +> B LABEL, A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 52: REVERSED WITH TWO ARGUMENTS + C LABEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 53: REVERSED WITH TWO ARGUMENTS + NEXT +============================================================ +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> -> \TYPE {} +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {2} +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 54: REVERSED WITH TWO ARGUMENTS + C LABEL < A LABEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {2} +============================================================ +============================================================ +TEST 55: REVERSED WITH TWO ARGUMENTS + DEFAULT: B LABEL > C LABEL +============================================================ +\UseHookWithArguments{REVERSED WITH TWO ARGUMENTS}{2}{arg_1}{arg_2}=> + + + + +-> The hook 'REVERSED WITH TWO ARGUMENTS' (2 arguments): +> Code chunks: +> A LABEL -> \TYPE {} +> B LABEL -> \TYPE {} +> C LABEL -> \TYPE {} +> Document-level (top-level) code (executed first): +> -> \TYPE {} +> Extra code for next invocation: +> --- +> Rules: +> C LABEL|A LABEL with relation < +> C LABEL|B LABEL with default relation < +> Execution order (after reversal and applying rules): +> B LABEL, C LABEL, A LABEL. + } +l. ... {2} +============================================================ +============================================================ +============================================================ +TEST 56: After \begin {document} +============================================================ +============================================================ +TEST 57: Commands +============================================================ + + + +============================================================ + + + +============================================================ + + + +============================================================ + + + +============================================================ +============================================================ +!!!! If this test changes the documentation needs updating !!!!