]> gitweb.michael.orlitzky.com - dead/htsn-import.git/commitdiff
Add two more samples of weird scoresxml.
authorMichael Orlitzky <michael@orlitzky.com>
Fri, 17 Oct 2014 17:12:16 +0000 (13:12 -0400)
committerMichael Orlitzky <michael@orlitzky.com>
Fri, 17 Oct 2014 17:12:16 +0000 (13:12 -0400)
test/shell/import-duplicates.test
test/xml/scoresxml-empty-numeral.xml [new file with mode: 0644]
test/xml/scoresxml-empty-type.xml [new file with mode: 0644]

index 656bd8ad15ba7e75078c8a6b49b6c4c5a55df436..d2ea767f65dabb1f6bdf11c76d87edd3bbec82a4 100644 (file)
@@ -16,7 +16,7 @@ rm -f shelltest.sqlite3
 # and a newsxml that aren't really supposed to import.
 find ./test/xml -maxdepth 1 -name '*.xml' | wc -l
 >>>
-36
+38
 >>>= 0
 
 # Run the imports again; we should get complaints about the duplicate
@@ -24,7 +24,7 @@ find ./test/xml -maxdepth 1 -name '*.xml' | wc -l
 # occurrences of the string 'ERROR'.
 ./dist/build/htsn-import/htsn-import -c 'shelltest.sqlite3' test/xml/*.xml 2>&1 | grep ERROR | wc -l
 >>>
-64
+68
 >>>= 0
 
 # Finally, clean up after ourselves.
diff --git a/test/xml/scoresxml-empty-numeral.xml b/test/xml/scoresxml-empty-numeral.xml
new file mode 100644 (file)
index 0000000..2fac3a0
--- /dev/null
@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no" ?>\r<!DOCTYPE message PUBLIC "-//TSN//DTD Scores 1.0/EN" "scoresxml.dtd">\r<message>\r<XML_File_ID>21984547</XML_File_ID>\r<heading>BC-ACF+109:104*11712999</heading>\r<game_id></game_id>\r<schedule_id></schedule_id>\r<category>Scores</category>\r<sport>NBA</sport>\r<location>\r<city>Sacramento</city>\r<state>CA</state>\r<country>USA</country>\r</location>\r<seasontype></seasontype>\r<game>\r<vteam id="109">Sacramento</vteam>\r<hteam id="104">Brooklyn</hteam>\r<vscore>117</vscore>\r<hscore>129</hscore>\r<status numeral="" type="F">FINAL</status>\r</game>\r<time_stamp> October 15, 2014, at 10:17 AM ET </time_stamp>\r</message>\r
\ No newline at end of file
diff --git a/test/xml/scoresxml-empty-type.xml b/test/xml/scoresxml-empty-type.xml
new file mode 100644 (file)
index 0000000..46df72b
--- /dev/null
@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no" ?>\r<!DOCTYPE message PUBLIC "-//TSN//DTD Scores 1.0/EN" "scoresxml.dtd">\r<message>\r<XML_File_ID>21986921</XML_File_ID>\r<heading>BC-ADP+126:141*  4  6 3R 1:05</heading>\r<game_id>19289</game_id>\r<schedule_id>19289</schedule_id>\r<category>Scores</category>\r<sport>NHL</sport>\r<location>\r<city>Edmonton</city>\r<state>ALBERTA</state>\r<country>CANADA</country>\r</location>\r<location>\r<city>Arizona</city>\r<state>AZ</state>\r<country>USA</country>\r</location>\r<seasontype>Regular</seasontype>\r<game>\r<vteam id="126">Edmonton</vteam>\r<hteam id="141">Arizona</hteam>\r<vscore>4</vscore>\r<hscore>6</hscore>\r<time_r>1:05</time_r>\r<status numeral="3" type="">3 Period</status>\r<notes>Lauri Korpikoski slap shot is over the net.</notes>\r</game>\r<time_stamp> October 16, 2014, at 01:27 AM ET </time_stamp>\r</message>\r
\ No newline at end of file