diff options
author | Karl Berry <karl@freefriends.org> | 2008-06-14 18:55:27 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2008-06-14 18:55:27 +0000 |
commit | 8842febffdfa43a08856423a4ae0c13ffa2506e4 (patch) | |
tree | c58437a40b701d13a102d05fb91693d56a6e9d04 /Master/texmf-dist/doc/latex/oberdiek/test | |
parent | d7122615203188ff1f643c83d927322d109cf456 (diff) |
oberdiek update (13jun08)
git-svn-id: svn://tug.org/texlive/trunk@8732 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex/oberdiek/test')
-rw-r--r-- | Master/texmf-dist/doc/latex/oberdiek/test/letltxmacro-test1.tex | 2 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/oberdiek/test/letltxmacro-test2.tex | 69 |
2 files changed, 66 insertions, 5 deletions
diff --git a/Master/texmf-dist/doc/latex/oberdiek/test/letltxmacro-test1.tex b/Master/texmf-dist/doc/latex/oberdiek/test/letltxmacro-test1.tex index 3f9e112d562..759c833232c 100644 --- a/Master/texmf-dist/doc/latex/oberdiek/test/letltxmacro-test1.tex +++ b/Master/texmf-dist/doc/latex/oberdiek/test/letltxmacro-test1.tex @@ -65,7 +65,7 @@ \catcode`\%=14 % \catcode`\ =10 % \catcode13=5 % - \RequirePackage{letltxmacro}[2008/06/12]\relax + \RequirePackage{letltxmacro}[2008/06/13]\relax \RestoreCatcodes } \Test diff --git a/Master/texmf-dist/doc/latex/oberdiek/test/letltxmacro-test2.tex b/Master/texmf-dist/doc/latex/oberdiek/test/letltxmacro-test2.tex index b7e3f07570d..e98085bde88 100644 --- a/Master/texmf-dist/doc/latex/oberdiek/test/letltxmacro-test2.tex +++ b/Master/texmf-dist/doc/latex/oberdiek/test/letltxmacro-test2.tex @@ -32,7 +32,7 @@ \nofiles \documentclass{minimal} -\usepackage{letltxmacro}[2008/06/12] +\usepackage{letltxmacro}[2008/06/13] \usepackage{qstest} \IncludeTests{*} @@ -124,11 +124,21 @@ \LetLtxMacro\NewEmpty\empty \Expect*{\meaning\empty}{macro:->}% \Expect*{\meaning\NewEmpty}{macro:->}% + \def\TestA{\iffalse}% + \LetLtxMacro\TestB\TestA + \TestDef{TestB}{\iffalse }% + \TestEquals{TestA}{TestB}% \end{qstest} -\usepackage{etoolbox} +\usepackage{etoolbox}[2008/06/12] -\begin{qstest}{newrobustcmd}{newrobustcmd} - \newrobustcmd{\TestA}[1][\default]{TestA}% +\begin{qstest}{newrobustcmd}{oldnewrobustcmd} + \protected\edef\TestA{% + \noexpand\@testopt + \expandafter\noexpand\csname\string\TestA\endcsname + {\noexpand\default}% + }% + \expandafter\protected\expandafter + \def\csname\string\TestA\endcsname{TestA}% \SaveA \LetLtxMacro\TestB\TestA \TestDef{TestB}{\@testopt \\TestB {\default }}% @@ -140,6 +150,57 @@ \TestEquals{TestB}{TestC}% \CheckA \end{qstest} + +\begin{qstest}{newrobustcmd}{newrobustcmd} + \newrobustcmd{\TestA}[1][\default]{TestA}% + \SaveA + \LetLtxMacro\TestB\TestA + \TestDef{TestB}{\@protected@testopt \TestB \\TestB {\default }}% + \protected\edef\TestC{% + \noexpand\@protected@testopt + \noexpand\TestB + \expandafter\noexpand\csname\string\TestB\endcsname + {\noexpand\default}% + }% + \TestEquals{TestB}{TestC}% + \CheckA +\end{qstest} + +\begin{qstest}{robustifyopt}{robustifyopt} + \newcommand{\TestA}[2][\default]{}% + \TestDef{TestA}{\@protected@testopt \TestA \\TestA {\default }}% + \robustify\TestA + \TestDef{TestA}{\@protected@testopt \TestA \\TestA {\default }}% + \protected\edef\TestC{% + \noexpand\@protected@testopt + \noexpand\TestA + \expandafter\noexpand\csname\string\TestA\endcsname + {\noexpand\default}% + }% + \TestEquals{TestA}{TestC}% + \SaveA + \LetLtxMacro\TestB\TestA + \TestDef{TestB}{\@protected@testopt \TestB \\TestB {\default }}% + \protected\edef\TestC{% + \noexpand\@protected@testopt + \noexpand\TestB + \expandafter\noexpand\csname\string\TestB\endcsname + {\noexpand\default}% + }% + \TestEquals{TestB}{TestC}% + \CheckA +\end{qstest} + +\begin{qstest}{robustifydeclare}{robustifydeclare} + \DeclareRobustCommand\TestA{\iffalse}% + \robustify\TestA + \SaveA + \LetLtxMacro\TestB\TestA + \TestDef{TestB}{\iffalse }% + \protected\long\def\TestC{\iffalse}% + \TestEquals{TestB}{TestC}% + \CheckA +\end{qstest} \csname @@end\endcsname \endinput %% |