1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337
|
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Item:
%% Test suite for the verb substitution task in pre_process.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Bug description (add references to further descriptive files if possible):
%% In LaTeX, \begin{environment} opens a group which is ended by
%% \end{environment}, making definitions or font changes local within
%% this group. This was not seen by l2h.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Bug caused this behaviour (may be several descriptions):
%% Changes to the font (style, size) made within the environment are not
%% reverted after the environment closed.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Bug severity (low|bothers|problematic|urgent -- fixed|open -- message):
%% bothers -- fixed --
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Bug fix identification
%% (id -- l2h release (or releases for multiple fixes) -- location in file(s)):
%% jcl(env) -- 96.1h -- latex2html
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Author: Jens Lippmann <http://www-jb.cs.uni-sb.de/~www/people/lippmann>
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Change log (Mon/DD/YY -- author -- message):
%% jcl = Jens Lippmann
%%
%% Aug/13/96 -- jcl -- created
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Test suite decription:
%% The suite focuses on the substitution statements of the task in pre_process().
%% We have the following equivalence classes (written in perl style):
%%
%% $del, $dels, $deln are meta variables for delimiters.
%% Important: In this notation the dot (.) includes the newline (\n).
%%
%%
%% a): \\verb[a-zA-Z].*
%% not a \verb statement
%% Hint: \\verb[$del][^$del]*[$del] with $del in [a-zA-Z] was falsely
%% expanded in previous revisions.
%%
%% b): \\verb\*.*
%% $del be a char in [^\t \n]
%%
%% b1): \\verb\*\t*[$del][^$del]*[$del].*
%% \verb statement
%% $del may be escaped by &escape_rx_chars or not, hence the subclasses:
%% b11): $del is \w
%% b12): $del is \W
%%
%% b2): \\verb\*\t*[$del][^$del]*
%% not a \verb statement
%%
%% b3): \\verb\*\t*[ \n].*
%% not a \verb statement
%%
%% b1) or b2) or b3) => b)
%%
%% c): \\verb[^a-zA-Z*\t \n].*
%% <=>
%% \\verb[$del].* iff $del in [^a-zA-Z*\t \n]
%%
%% c1): \\verb[$del][^$del]*[$del].*
%% \verb statement, $del may be escaped by &escape_rx_chars or
%% not. Hence the subclasses:
%% c11): $del is \w
%% c12): $del is \W
%%
%% c2): \\verb[$del][^$del]*
%% not a \verb statement
%%
%% c1) or c2) => c)
%%
%% d): \\verb\t.*
%% $dels be in [^ \n\t], $deln be in [^ \n\t*]
%% d1): \\verb\t\t*\*.*
%% d11): \\verb\t\t*\*\t*[$dels][^$dels][$dels].*
%% \verb statement, $dels may be escaped by &escape_rx_chars
%% or not. Hence the subclasses:
%% d111): $dels is \w
%% d112): $dels is \W
%% d12): \\verb\t\t*\*\t*[$dels][^$dels]*
%% not a \verb statement
%% d13): \\verb\t\t*\*\t*[ \n].*
%% not a \verb statement
%%
%% d2): \\verb\t\t*[$deln].*
%% d21): \\verb\t\t*[$deln][^$deln][$deln].*
%% \verb statement, $deln may be escaped by &escape_rx_chars
%% or not. Hence the subclasses:
%% d211): $deln is \w
%% d212): $deln is \W
%% d22): \\verb\t\t*[$deln][^$deln]*
%% not a \verb statement
%%
%% d3): \\verb\t\t*[ \n].*
%% not a \verb statement
%%
%% d1) or d2) or d3) => d)
%%
%% e): \\verb[ \n].*
%% not a \verb statement
%%
%% a) or b) or c) or d) or e) => \\verb.*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Expected output of this suit:
%% tex: \verbxtestax = undefined control sequence
%% l2h: \verbxtestax = unknown command
%% html output should look like dvi output
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentstyle{article}
\begin{document}
\section*{Test Description}
Test suite for the verb substitution task in pre_process.
\begin{verbatim}
%% Test suite decription:
%% The suite focuses on the substitution statements of the task in pre_process().
%% We have the following equivalence classes (written in perl style):
%%
%% $del, $dels, $deln are meta variables for delimiters.
%% Important: In this notation the dot (.) includes the newline (\n).
%%
%%
%% a): \\verb[a-zA-Z].*
%% not a \verb statement
%% Hint: \\verb[$del][^$del]*[$del] with $del in [a-zA-Z] was falsely
%% expanded in previous revisions.
%%
%% b): \\verb\*.*
%% $del be a char in [^\t \n]
%%
%% b1): \\verb\*\t*[$del][^$del]*[$del].*
%% \verb statement
%% $del may be escaped by &escape_rx_chars or not, hence the subclasses:
%% b11): $del is \w
%% b12): $del is \W
%%
%% b2): \\verb\*\t*[$del][^$del]*
%% not a \verb statement
%%
%% b3): \\verb\*\t*[ \n].*
%% not a \verb statement
%%
%% b1) or b2) or b3) => b)
%%
%% c): \\verb[^a-zA-Z*\t \n].*
%% <=>
%% \\verb[$del].* iff $del in [^a-zA-Z*\t \n]
%%
%% c1): \\verb[$del][^$del]*[$del].*
%% \verb statement, $del may be escaped by &escape_rx_chars or
%% not. Hence the subclasses:
%% c11): $del is \w
%% c12): $del is \W
%%
%% c2): \\verb[$del][^$del]*
%% not a \verb statement
%%
%% c1) or c2) => c)
%%
%% d): \\verb\t.*
%% $dels be in [^ \n\t], $deln be in [^ \n\t*]
%% d1): \\verb\t\t*\*.*
%% d11): \\verb\t\t*\*\t*[$dels][^$dels][$dels].*
%% \verb statement, $dels may be escaped by &escape_rx_chars
%% or not. Hence the subclasses:
%% d111): $dels is \w
%% d112): $dels is \W
%% d12): \\verb\t\t*\*\t*[$dels][^$dels]*
%% not a \verb statement
%% d13): \\verb\t\t*\*\t*[ \n].*
%% not a \verb statement
%%
%% d2): \\verb\t\t*[$deln].*
%% d21): \\verb\t\t*[$deln][^$deln][$deln].*
%% \verb statement, $deln may be escaped by &escape_rx_chars
%% or not. Hence the subclasses:
%% d211): $deln is \w
%% d212): $deln is \W
%% d22): \\verb\t\t*[$deln][^$deln]*
%% not a \verb statement
%%
%% d3): \\verb\t\t*[ \n].*
%% not a \verb statement
%%
%% d1) or d2) or d3) => d)
%%
%% e): \\verb[ \n].*
%% not a \verb statement
%%
%% a) or b) or c) or d) or e) => \\verb.*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Expected output of this suit:
%% tex: \verbxtestax = undefined control sequence
%% l2h: \verbxtestax = unknown command
%% html output should look like dvi output
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
The tests have passed if LaTeX2HTML reports {\bf only} verbxtestax to be
an unknown command, and if the HTML output looks like:
testb11
testb11
testb11
testb12
testb12
testb12
testc11
testc12
testd111
testd111
testd111
testd112
testd112
testd211
testd212
x y\ test1
test2 test3 test4\ \\\ \
\end{verbatim}
\section*{Test Part}
%%% The Tests matching the equivalence classes.
%%% Commented-out tests don't run in LaTeX, so testing seems
%%% to be obsolete there.
%%% Note: Test cases should contain zero, one or more tabs,
%%% zero, one or more chars of verb contents and several
%%% combinations of failure and success test cases.
%%% Tests for a):
%%% false delimiter, should fail
\verbxtestax
%%% Tests for b):
%%% b11): correct \w delimiter, should pass
\verb*xtestb11x
\verb* xtestb11x
\verb* xtestb11x
%%% b12): correct \W delimiters, should pass
\verb*/testb12/
\verb**testb12*
\verb*\testb12\
%%% b2): no closing delimiter, should fail
%\verb*xtestb2
%%% b3): no delimiter, should fail
%testb3\verb*
%%% Tests for c):
%%% c11): correct \w delimiter, should pass
\verb_testc11_
%%% c12): correct \W delimiter, should pass
\verb/testc12/
%%% c2): no closing delimiter, should fail
%\verb_testc2
%%% Tests for d):
%%% d111): correct \w delimiter for \verb\t\t*\*, should pass
\verb *_testd111_
\verb * _testd111_
\verb * _testd111_
%%% d112): correct \W delimiter for \verb\t\t*\*, should pass
\verb */testd112/
\verb **testd112*
%%% d12): no closing delimiter for \verb\t\t*\*, should fail
%\verb *_testd12
%%% d13): no delimiter for \verb\t\t*\*, should fail
%testd13\verb *
%%% d211): correct \w delimiter for \verb\t\t*, should pass
\verb xtestd211x
%%% d212): correct \W delimiter for \verb\t\t*, should pass
\verb /testd212/
%%% d22): no closing delimiter for \verb\t\t*, should fail
%\verb /testd22
%%% d3): no delimiter for \verb\t\t*, should fail
%testd3\verb
%%% Tests for e):
%teste\verb
%%% Missing: combinatoric tests.
%%% Stress tests (should pass):
\verb * /x
y\
test1
/
test2\verb\ \\verb\\ test3\verb*\ \ test4\verb**\ \\\ \*
\end{document}
|