-
Task
-
Resolution: Done
-
Normal
-
None
-
None
Create a single tdml file that contains the schema(s) and tests necessary to test the following escape scheme scenarios:
EC = escapeCharacter
EEC = escapeEscapeCharacter
PTERM = delimiter
Each line is a separate scenario. The first block is the input and the second is the expected output.
> (EC=EEC)!=PTERM[1], EC=EEC=/ PTERM=;
> foo;bar <x>foo</x><y>bar</y>
> foo/bar <x>foobar</x>
> foo/;bar <x>foo;bar</x>
> foo//;bar <x>foo/;bar</x>
> foo///bar <x>foo//bar</x> (Tricky!)
> foo///;bar <x>foo/;bar</x>
> foo; <x>foo</x> if PTERM is terminator or postfix sep. Parse Error otherwise.
> foo/; <x>foo;</x> Parse error if PTERM is required terminating markup.
> foo/;; <x>foo;</x> if PTERM is terminator or postfix sep. Parse Error otherwise
> foo//; <x>foo/</x> if PTERM is terminator or postfix sep. Parse Error otherwise
> foo///; <x>foo/;</x> (Tricky) if PTERM is infix separator or not-required terminator. Parse Error otherwise.
> foo/ <x>foo</x> (Tricky) if PTERM is infix separator or not-required terminator. Parse Error otherwise.
> foo/// <x>foo/</x> if PTERM is infix separator or not-required terminator.
>
>
> (EEC = PTERM[1] != EC) EC="/" EEC="$" PTERM="$;"
>
> foo$;bar <x>foo</x><y>bar</y>
> foo/$;bar <x>foo</x><y>bar</x>
> foo$/$;bar <x>foo/</x><y>bar</y>
> foo$$;bar <x>foo$</x><y>bar</y>
> foo//$;bar <x>foo</x><y>bar</y> (Tricky)
> foo//////////bar <x>foobar</x> (all lonely ECs)
> foo$$$$$bar <x>foo$$$$$bar</x> (all lonely EECs)
> foo$//;bar <x>foo/;bar</x>
> foo$/$$;bar <x>foo/$</x><y>bar</y>
> foo$; <x>foo</x> parse error if PTERM is infix sep
> foo/$; <x>foo$;</x> parse error if PTERM is required terminator.
> foo$/$; <x>foo/</x> if PTERM is terminator or postfix sep. PE otherwise.
> foo$$/$; <x>foo$/</x> if PTERM is terminator or postfix sep. PE otherwise.
> foo$$$//$; <x>foo$$/$;</x> parse error if PTERM is required terminator
>
>
>
> (EC = PTERM[1]) != EEC EC=/ EEC=$ TERM=/;
>
> foo/;bar <x>foo</x><y>bar</y>
> foo$/;bar <x>foo/;bar</y>
> foo$$/;bar <x>foo$</x><y>bar</y>
> foo//; bar <x>foo/;bar</x>
> foo///;bar <x>foo/</x><y>bar</y>
> foo$//;bar <x>foo/</x><y>bar</y>
> foo$///;bar <x>foo//;bar</x> (Tricky!)
> foo$////;bar <x>foo//;bar</x> (Tricky!)
> foo$///////;bar <x>foo//;bar</x> (Tricky!)
> foo/; <x>foo</x> if PTERM is terminator or postfix sep. PE otherwise.
> foo$/; <x>foo/;</x> if PTERM is terminator or postfix sep. PE otherwise.
> foo$$/; <x>foo$/;</x> if PTERM is not required. PE otherwise
> foo$//; <x>foo/</x> if PTERM is terminator or postfix sep. PE otherwise
> foo$/$/$/; <x>foo///;</x>if PTERM is not required. PE otherwise
>
> EC=EEC=PTERM[1] EC=/ PTERM=/;
>
> foo/;bar <x>foo<x><y>bar</y>
> foo//;bar <x>foo/;bar</y>
> foo///;bar <x>foo/</x><y>bar</y>
> foo////bar <x>foo//bar</x>
> foo////;bar <x>foo//;bar<x> (Tricky)
> foo/////;bar <x>foo//<x><y>bar</y> (Tricky)
> foo <x>foo</x> if PTERM is not required. PE otherwise
> foo/; <x>foo</x> if PTERM is terminator or postfix sep. PE otherwise.
> foo//; <x>foo/;</x> if PTERM is not required. PE otherwise
> foo/// <x>foo/</x> if PTERM is not required. PE otherwise
> foo///; <x>foo</x> if PTERM is terminator or postfix sep. PE otherwise.
> foo////; <x>foo//;</x> if PTERM is not required. PE otherwise
- relates to
-
DFDL-961 Escape Scheme Scenario "scenario3_11_postfix" failing
- Open