Test results for Linux |
Test for a new elements inserted at the levels specified with and without scope restrictions.
Pass
cat _INPUT_DATA_ ¦ xmlfy -T0 name results -T1 insert author "Arthur Gouros" -T2:2-$ insert league premier -T2:1 insert field "League Type"
Team Won Lost Drawn Barcelona 5 1 2 Manchester 4 2 2 Milan 2 2 4
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE results SYSTEM "xmlfy.dtd"> <results> <author>Arthur Gouros</author> <line> <field>League Type</field> <field>Team</field> <field>Won</field> <field>Lost</field> <field>Drawn</field> </line> <line> <league>premier</league> <field>Barcelona</field> <field>5</field> <field>1</field> <field>2</field> </line> <line> <league>premier</league> <field>Manchester</field> <field>4</field> <field>2</field> <field>2</field> </line> <line> <league>premier</league> <field>Milan</field> <field>2</field> <field>2</field> <field>4</field> </line> </results>