From 57ba362eae6e8209cf560555fd4cc4bb76dbe2a1 Mon Sep 17 00:00:00 2001 From: Stefan Radomski Date: Wed, 8 Jul 2015 22:03:03 +0200 Subject: done.event bug and prolog tests Fixed the done.event bug and added first prolog transformed IRP tests --- CMakeLists.txt | 1 + README.md | 32 + src/uscxml/Interpreter.cpp | 73 +- src/uscxml/Interpreter.h | 2 +- src/uscxml/interpreter/InterpreterDraft6.cpp | 12 +- src/uscxml/interpreter/InterpreterRC.cpp | 18 +- .../plugins/datamodel/prolog/swi/SWIDataModel.cpp | 6 +- .../plugins/datamodel/prolog/swi/SWIDataModel.new | 962 +++++++++++++++++++++ src/uscxml/server/HTTPServer.cpp | 2 +- src/uscxml/transform/ChartToFSM.cpp | 35 +- src/uscxml/transform/ChartToFSM.h | 2 +- src/uscxml/transform/ChartToFlatSCXML.h | 4 +- test/CMakeLists.txt | 10 + test/src/test-doneevent.cpp | 63 ++ test/src/test-issue-reporting.cpp | 2 +- test/src/test-lifecycle.cpp | 4 +- test/w3c/confProlog.xsl | 770 +++++++++++++++++ test/w3c/convert-tests.sh | 18 +- test/w3c/prolog/robots.txt | 96 ++ test/w3c/prolog/test144.scxml | 27 + test/w3c/prolog/test147.scxml | 35 + test/w3c/prolog/test148.scxml | 36 + test/w3c/prolog/test149.scxml | 31 + test/w3c/prolog/test150.scxml | 45 + test/w3c/prolog/test151.scxml | 45 + test/w3c/prolog/test152.scxml | 51 ++ test/w3c/prolog/test153.scxml | 42 + test/w3c/prolog/test155.scxml | 31 + test/w3c/prolog/test156.scxml | 33 + test/w3c/prolog/test158.scxml | 29 + test/w3c/prolog/test159.scxml | 26 + test/w3c/prolog/test172.scxml | 25 + test/w3c/prolog/test173.scxml | 26 + test/w3c/prolog/test174.scxml | 26 + test/w3c/prolog/test175.scxml | 32 + test/w3c/prolog/test176.scxml | 35 + test/w3c/prolog/test178.scxml | 27 + test/w3c/prolog/test179.scxml | 23 + test/w3c/prolog/test183.scxml | 25 + test/w3c/prolog/test185.scxml | 27 + test/w3c/prolog/test186.scxml | 36 + test/w3c/prolog/test187.scxml | 38 + test/w3c/prolog/test189.scxml | 27 + test/w3c/prolog/test190.scxml | 40 + test/w3c/prolog/test191.scxml | 37 + test/w3c/prolog/test192.scxml | 52 ++ test/w3c/prolog/test193.scxml | 29 + test/w3c/prolog/test194.scxml | 26 + test/w3c/prolog/test198.scxml | 23 + test/w3c/prolog/test199.scxml | 22 + test/w3c/prolog/test200.scxml | 22 + test/w3c/prolog/test201.scxml | 23 + test/w3c/prolog/test205.scxml | 34 + test/w3c/prolog/test207.scxml | 55 ++ test/w3c/prolog/test208.scxml | 24 + test/w3c/prolog/test210.scxml | 28 + test/w3c/prolog/test215.scxml | 35 + test/w3c/prolog/test216.scxml | 28 + test/w3c/prolog/test216sub1.scxml | 5 + test/w3c/prolog/test220.scxml | 29 + test/w3c/prolog/test223.scxml | 35 + test/w3c/prolog/test224.scxml | 36 + test/w3c/prolog/test225.scxml | 42 + test/w3c/prolog/test226.scxml | 26 + test/w3c/prolog/test226sub1.scxml | 14 + test/w3c/prolog/test228.scxml | 37 + test/w3c/prolog/test229.scxml | 46 + test/w3c/prolog/test230.scxml | 60 ++ test/w3c/prolog/test232.scxml | 41 + test/w3c/prolog/test233.scxml | 42 + test/w3c/prolog/test234.scxml | 69 ++ test/w3c/prolog/test235.scxml | 29 + test/w3c/prolog/test236.scxml | 43 + test/w3c/prolog/test237.scxml | 45 + test/w3c/prolog/test239.scxml | 35 + test/w3c/prolog/test239sub1.scxml | 5 + test/w3c/prolog/test240.scxml | 71 ++ test/w3c/prolog/test241.scxml | 96 ++ test/w3c/prolog/test242.scxml | 56 ++ test/w3c/prolog/test242sub1.scxml | 5 + test/w3c/prolog/test243.scxml | 41 + test/w3c/prolog/test244.scxml | 45 + test/w3c/prolog/test245.scxml | 40 + test/w3c/prolog/test247.scxml | 28 + test/w3c/prolog/test250.scxml | 39 + test/w3c/prolog/test252.scxml | 48 + test/w3c/prolog/test253.scxml | 75 ++ test/w3c/prolog/test276.scxml | 22 + test/w3c/prolog/test276sub1.scxml | 16 + test/w3c/prolog/test277.scxml | 32 + test/w3c/prolog/test278.scxml | 23 + test/w3c/prolog/test279.scxml | 24 + test/w3c/prolog/test280.scxml | 33 + test/w3c/prolog/test286.scxml | 23 + test/w3c/prolog/test287.scxml | 24 + test/w3c/prolog/test288.scxml | 25 + test/w3c/prolog/test294.scxml | 46 + test/w3c/prolog/test298.scxml | 32 + test/w3c/prolog/test301.scxml | 19 + test/w3c/prolog/test302.scxml | 21 + test/w3c/prolog/test303.scxml | 26 + test/w3c/prolog/test304.scxml | 19 + test/w3c/prolog/test307.scxml | 35 + test/w3c/prolog/test309.scxml | 18 + test/w3c/prolog/test310.scxml | 21 + test/w3c/prolog/test311.scxml | 22 + test/w3c/prolog/test312.scxml | 25 + test/w3c/prolog/test313.scxml | 26 + test/w3c/prolog/test314.scxml | 35 + test/w3c/prolog/test318.scxml | 32 + test/w3c/prolog/test319.scxml | 25 + test/w3c/prolog/test321.scxml | 21 + test/w3c/prolog/test322.scxml | 34 + test/w3c/prolog/test323.scxml | 21 + test/w3c/prolog/test324.scxml | 25 + test/w3c/prolog/test325.scxml | 23 + test/w3c/prolog/test326.scxml | 37 + test/w3c/prolog/test329.scxml | 54 ++ test/w3c/prolog/test330.scxml | 28 + test/w3c/prolog/test331.scxml | 59 ++ test/w3c/prolog/test332.scxml | 34 + test/w3c/prolog/test333.scxml | 21 + test/w3c/prolog/test335.scxml | 21 + test/w3c/prolog/test336.scxml | 31 + test/w3c/prolog/test337.scxml | 21 + test/w3c/prolog/test338.scxml | 43 + test/w3c/prolog/test339.scxml | 21 + test/w3c/prolog/test342.scxml | 31 + test/w3c/prolog/test343.scxml | 35 + test/w3c/prolog/test344.scxml | 28 + test/w3c/prolog/test346.scxml | 54 ++ test/w3c/prolog/test347.scxml | 44 + test/w3c/prolog/test348.scxml | 21 + test/w3c/prolog/test349.scxml | 33 + test/w3c/prolog/test350.scxml | 28 + test/w3c/prolog/test351.scxml | 47 + test/w3c/prolog/test352.scxml | 32 + test/w3c/prolog/test354.scxml | 52 ++ test/w3c/prolog/test355.scxml | 20 + test/w3c/prolog/test364.scxml | 79 ++ test/w3c/prolog/test372.scxml | 33 + test/w3c/prolog/test375.scxml | 28 + test/w3c/prolog/test376.scxml | 28 + test/w3c/prolog/test377.scxml | 31 + test/w3c/prolog/test378.scxml | 31 + test/w3c/prolog/test387.scxml | 93 ++ test/w3c/prolog/test388.scxml | 74 ++ test/w3c/prolog/test396.scxml | 21 + test/w3c/prolog/test399.scxml | 65 ++ test/w3c/prolog/test401.scxml | 25 + test/w3c/prolog/test402.scxml | 42 + test/w3c/prolog/test403a.scxml | 46 + test/w3c/prolog/test403b.scxml | 40 + test/w3c/prolog/test403c.scxml | 53 ++ test/w3c/prolog/test404.scxml | 56 ++ test/w3c/prolog/test405.scxml | 66 ++ test/w3c/prolog/test406.scxml | 60 ++ test/w3c/prolog/test407.scxml | 27 + test/w3c/prolog/test409.scxml | 36 + test/w3c/prolog/test411.scxml | 36 + test/w3c/prolog/test412.scxml | 52 ++ test/w3c/prolog/test413.scxml | 44 + test/w3c/prolog/test415.scxml | 13 + test/w3c/prolog/test416.scxml | 27 + test/w3c/prolog/test417.scxml | 36 + test/w3c/prolog/test419.scxml | 22 + test/w3c/prolog/test421.scxml | 31 + test/w3c/prolog/test422.scxml | 81 ++ test/w3c/prolog/test423.scxml | 29 + test/w3c/prolog/test446.txt | 1 + test/w3c/prolog/test487.scxml | 25 + test/w3c/prolog/test488.scxml | 35 + test/w3c/prolog/test495.scxml | 28 + test/w3c/prolog/test496.scxml | 21 + test/w3c/prolog/test500.scxml | 21 + test/w3c/prolog/test501.scxml | 25 + test/w3c/prolog/test503.scxml | 43 + test/w3c/prolog/test504.scxml | 79 ++ test/w3c/prolog/test505.scxml | 52 ++ test/w3c/prolog/test506.scxml | 56 ++ test/w3c/prolog/test509.scxml | 24 + test/w3c/prolog/test510.scxml | 29 + test/w3c/prolog/test513.txt | 16 + test/w3c/prolog/test518.scxml | 25 + test/w3c/prolog/test519.scxml | 25 + test/w3c/prolog/test520.scxml | 27 + test/w3c/prolog/test521.scxml | 27 + test/w3c/prolog/test522.scxml | 27 + test/w3c/prolog/test525.scxml | 32 + test/w3c/prolog/test527.scxml | 28 + test/w3c/prolog/test528.scxml | 33 + test/w3c/prolog/test529.scxml | 28 + test/w3c/prolog/test530.scxml | 34 + test/w3c/prolog/test531.scxml | 26 + test/w3c/prolog/test532.scxml | 26 + test/w3c/prolog/test533.scxml | 67 ++ test/w3c/prolog/test534.scxml | 24 + test/w3c/prolog/test539.txt | 4 + test/w3c/prolog/test540.txt | 3 + test/w3c/prolog/test550.scxml | 23 + test/w3c/prolog/test551.scxml | 25 + test/w3c/prolog/test552.scxml | 22 + test/w3c/prolog/test552.txt | 1 + test/w3c/prolog/test553.scxml | 27 + test/w3c/prolog/test554.scxml | 31 + test/w3c/prolog/test557.txt | 4 + test/w3c/prolog/test558.txt | 3 + test/w3c/prolog/test567.scxml | 37 + test/w3c/prolog/test570.scxml | 48 + test/w3c/prolog/test576.scxml | 43 + test/w3c/prolog/test577.scxml | 25 + test/w3c/prolog/test579.scxml | 60 ++ test/w3c/prolog/test580.scxml | 45 + test/w3c/promela/test150.scxml | 80 +- 214 files changed, 8651 insertions(+), 113 deletions(-) create mode 100644 src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.new create mode 100644 test/src/test-doneevent.cpp create mode 100644 test/w3c/confProlog.xsl create mode 100644 test/w3c/prolog/robots.txt create mode 100644 test/w3c/prolog/test144.scxml create mode 100644 test/w3c/prolog/test147.scxml create mode 100644 test/w3c/prolog/test148.scxml create mode 100644 test/w3c/prolog/test149.scxml create mode 100644 test/w3c/prolog/test150.scxml create mode 100644 test/w3c/prolog/test151.scxml create mode 100644 test/w3c/prolog/test152.scxml create mode 100644 test/w3c/prolog/test153.scxml create mode 100644 test/w3c/prolog/test155.scxml create mode 100644 test/w3c/prolog/test156.scxml create mode 100644 test/w3c/prolog/test158.scxml create mode 100644 test/w3c/prolog/test159.scxml create mode 100644 test/w3c/prolog/test172.scxml create mode 100644 test/w3c/prolog/test173.scxml create mode 100644 test/w3c/prolog/test174.scxml create mode 100644 test/w3c/prolog/test175.scxml create mode 100644 test/w3c/prolog/test176.scxml create mode 100644 test/w3c/prolog/test178.scxml create mode 100644 test/w3c/prolog/test179.scxml create mode 100644 test/w3c/prolog/test183.scxml create mode 100644 test/w3c/prolog/test185.scxml create mode 100644 test/w3c/prolog/test186.scxml create mode 100644 test/w3c/prolog/test187.scxml create mode 100644 test/w3c/prolog/test189.scxml create mode 100644 test/w3c/prolog/test190.scxml create mode 100644 test/w3c/prolog/test191.scxml create mode 100644 test/w3c/prolog/test192.scxml create mode 100644 test/w3c/prolog/test193.scxml create mode 100644 test/w3c/prolog/test194.scxml create mode 100644 test/w3c/prolog/test198.scxml create mode 100644 test/w3c/prolog/test199.scxml create mode 100644 test/w3c/prolog/test200.scxml create mode 100644 test/w3c/prolog/test201.scxml create mode 100644 test/w3c/prolog/test205.scxml create mode 100644 test/w3c/prolog/test207.scxml create mode 100644 test/w3c/prolog/test208.scxml create mode 100644 test/w3c/prolog/test210.scxml create mode 100644 test/w3c/prolog/test215.scxml create mode 100644 test/w3c/prolog/test216.scxml create mode 100644 test/w3c/prolog/test216sub1.scxml create mode 100644 test/w3c/prolog/test220.scxml create mode 100644 test/w3c/prolog/test223.scxml create mode 100644 test/w3c/prolog/test224.scxml create mode 100644 test/w3c/prolog/test225.scxml create mode 100644 test/w3c/prolog/test226.scxml create mode 100644 test/w3c/prolog/test226sub1.scxml create mode 100644 test/w3c/prolog/test228.scxml create mode 100644 test/w3c/prolog/test229.scxml create mode 100644 test/w3c/prolog/test230.scxml create mode 100644 test/w3c/prolog/test232.scxml create mode 100644 test/w3c/prolog/test233.scxml create mode 100644 test/w3c/prolog/test234.scxml create mode 100644 test/w3c/prolog/test235.scxml create mode 100644 test/w3c/prolog/test236.scxml create mode 100644 test/w3c/prolog/test237.scxml create mode 100644 test/w3c/prolog/test239.scxml create mode 100644 test/w3c/prolog/test239sub1.scxml create mode 100644 test/w3c/prolog/test240.scxml create mode 100644 test/w3c/prolog/test241.scxml create mode 100644 test/w3c/prolog/test242.scxml create mode 100644 test/w3c/prolog/test242sub1.scxml create mode 100644 test/w3c/prolog/test243.scxml create mode 100644 test/w3c/prolog/test244.scxml create mode 100644 test/w3c/prolog/test245.scxml create mode 100644 test/w3c/prolog/test247.scxml create mode 100644 test/w3c/prolog/test250.scxml create mode 100644 test/w3c/prolog/test252.scxml create mode 100644 test/w3c/prolog/test253.scxml create mode 100644 test/w3c/prolog/test276.scxml create mode 100644 test/w3c/prolog/test276sub1.scxml create mode 100644 test/w3c/prolog/test277.scxml create mode 100644 test/w3c/prolog/test278.scxml create mode 100644 test/w3c/prolog/test279.scxml create mode 100644 test/w3c/prolog/test280.scxml create mode 100644 test/w3c/prolog/test286.scxml create mode 100644 test/w3c/prolog/test287.scxml create mode 100644 test/w3c/prolog/test288.scxml create mode 100644 test/w3c/prolog/test294.scxml create mode 100644 test/w3c/prolog/test298.scxml create mode 100644 test/w3c/prolog/test301.scxml create mode 100644 test/w3c/prolog/test302.scxml create mode 100644 test/w3c/prolog/test303.scxml create mode 100644 test/w3c/prolog/test304.scxml create mode 100644 test/w3c/prolog/test307.scxml create mode 100644 test/w3c/prolog/test309.scxml create mode 100644 test/w3c/prolog/test310.scxml create mode 100644 test/w3c/prolog/test311.scxml create mode 100644 test/w3c/prolog/test312.scxml create mode 100644 test/w3c/prolog/test313.scxml create mode 100644 test/w3c/prolog/test314.scxml create mode 100644 test/w3c/prolog/test318.scxml create mode 100644 test/w3c/prolog/test319.scxml create mode 100644 test/w3c/prolog/test321.scxml create mode 100644 test/w3c/prolog/test322.scxml create mode 100644 test/w3c/prolog/test323.scxml create mode 100644 test/w3c/prolog/test324.scxml create mode 100644 test/w3c/prolog/test325.scxml create mode 100644 test/w3c/prolog/test326.scxml create mode 100644 test/w3c/prolog/test329.scxml create mode 100644 test/w3c/prolog/test330.scxml create mode 100644 test/w3c/prolog/test331.scxml create mode 100644 test/w3c/prolog/test332.scxml create mode 100644 test/w3c/prolog/test333.scxml create mode 100644 test/w3c/prolog/test335.scxml create mode 100644 test/w3c/prolog/test336.scxml create mode 100644 test/w3c/prolog/test337.scxml create mode 100644 test/w3c/prolog/test338.scxml create mode 100644 test/w3c/prolog/test339.scxml create mode 100644 test/w3c/prolog/test342.scxml create mode 100644 test/w3c/prolog/test343.scxml create mode 100644 test/w3c/prolog/test344.scxml create mode 100644 test/w3c/prolog/test346.scxml create mode 100644 test/w3c/prolog/test347.scxml create mode 100644 test/w3c/prolog/test348.scxml create mode 100644 test/w3c/prolog/test349.scxml create mode 100644 test/w3c/prolog/test350.scxml create mode 100644 test/w3c/prolog/test351.scxml create mode 100644 test/w3c/prolog/test352.scxml create mode 100644 test/w3c/prolog/test354.scxml create mode 100644 test/w3c/prolog/test355.scxml create mode 100644 test/w3c/prolog/test364.scxml create mode 100644 test/w3c/prolog/test372.scxml create mode 100644 test/w3c/prolog/test375.scxml create mode 100644 test/w3c/prolog/test376.scxml create mode 100644 test/w3c/prolog/test377.scxml create mode 100644 test/w3c/prolog/test378.scxml create mode 100644 test/w3c/prolog/test387.scxml create mode 100644 test/w3c/prolog/test388.scxml create mode 100644 test/w3c/prolog/test396.scxml create mode 100644 test/w3c/prolog/test399.scxml create mode 100644 test/w3c/prolog/test401.scxml create mode 100644 test/w3c/prolog/test402.scxml create mode 100644 test/w3c/prolog/test403a.scxml create mode 100644 test/w3c/prolog/test403b.scxml create mode 100644 test/w3c/prolog/test403c.scxml create mode 100644 test/w3c/prolog/test404.scxml create mode 100644 test/w3c/prolog/test405.scxml create mode 100644 test/w3c/prolog/test406.scxml create mode 100644 test/w3c/prolog/test407.scxml create mode 100644 test/w3c/prolog/test409.scxml create mode 100644 test/w3c/prolog/test411.scxml create mode 100644 test/w3c/prolog/test412.scxml create mode 100644 test/w3c/prolog/test413.scxml create mode 100644 test/w3c/prolog/test415.scxml create mode 100644 test/w3c/prolog/test416.scxml create mode 100644 test/w3c/prolog/test417.scxml create mode 100644 test/w3c/prolog/test419.scxml create mode 100644 test/w3c/prolog/test421.scxml create mode 100644 test/w3c/prolog/test422.scxml create mode 100644 test/w3c/prolog/test423.scxml create mode 100644 test/w3c/prolog/test446.txt create mode 100644 test/w3c/prolog/test487.scxml create mode 100644 test/w3c/prolog/test488.scxml create mode 100644 test/w3c/prolog/test495.scxml create mode 100644 test/w3c/prolog/test496.scxml create mode 100644 test/w3c/prolog/test500.scxml create mode 100644 test/w3c/prolog/test501.scxml create mode 100644 test/w3c/prolog/test503.scxml create mode 100644 test/w3c/prolog/test504.scxml create mode 100644 test/w3c/prolog/test505.scxml create mode 100644 test/w3c/prolog/test506.scxml create mode 100644 test/w3c/prolog/test509.scxml create mode 100644 test/w3c/prolog/test510.scxml create mode 100644 test/w3c/prolog/test513.txt create mode 100644 test/w3c/prolog/test518.scxml create mode 100644 test/w3c/prolog/test519.scxml create mode 100644 test/w3c/prolog/test520.scxml create mode 100644 test/w3c/prolog/test521.scxml create mode 100644 test/w3c/prolog/test522.scxml create mode 100644 test/w3c/prolog/test525.scxml create mode 100644 test/w3c/prolog/test527.scxml create mode 100644 test/w3c/prolog/test528.scxml create mode 100644 test/w3c/prolog/test529.scxml create mode 100644 test/w3c/prolog/test530.scxml create mode 100644 test/w3c/prolog/test531.scxml create mode 100644 test/w3c/prolog/test532.scxml create mode 100644 test/w3c/prolog/test533.scxml create mode 100644 test/w3c/prolog/test534.scxml create mode 100644 test/w3c/prolog/test539.txt create mode 100644 test/w3c/prolog/test540.txt create mode 100644 test/w3c/prolog/test550.scxml create mode 100644 test/w3c/prolog/test551.scxml create mode 100644 test/w3c/prolog/test552.scxml create mode 100644 test/w3c/prolog/test552.txt create mode 100644 test/w3c/prolog/test553.scxml create mode 100644 test/w3c/prolog/test554.scxml create mode 100644 test/w3c/prolog/test557.txt create mode 100644 test/w3c/prolog/test558.txt create mode 100644 test/w3c/prolog/test567.scxml create mode 100644 test/w3c/prolog/test570.scxml create mode 100644 test/w3c/prolog/test576.scxml create mode 100644 test/w3c/prolog/test577.scxml create mode 100644 test/w3c/prolog/test579.scxml create mode 100644 test/w3c/prolog/test580.scxml diff --git a/CMakeLists.txt b/CMakeLists.txt index bed2f59..038d7cb 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -353,6 +353,7 @@ else() OPTION(BUILD_TESTS_W3C_ECMA "Create W3C ECMAScript tests" ON) OPTION(BUILD_TESTS_W3C_XPATH "Create W3C XPath tests" ON) OPTION(BUILD_TESTS_W3C_LUA "Create W3C Lua tests" ON) + OPTION(BUILD_TESTS_W3C_PROLOG "Create W3C Prolog tests" ON) OPTION(BUILD_TESTS_W3C_PROMELA "Create W3C Promela tests" ON) OPTION(BUILD_TESTS_FSM_ECMA "Create FSM converted W3C ECMAScript tests" ON) diff --git a/README.md b/README.md index 60f803b..ecbfae7 100644 --- a/README.md +++ b/README.md @@ -66,6 +66,38 @@ even in C# and Java. It runs on Linux, Windows, Raspberry Pi-DBUILD_TESTS=ON via CMake: + + $ cmake -DBUILD_TESTS=ON && make + +Afterwards, you can run the various tests. There are more than 1500 tests in total, so maybe restrict yourself to +some subset. + +*W3C Tests ECMAScript Datamodel* + + $ ctest -L "^ecma/test" + [...] + $ 100% tests passed, 0 tests failed out of 196 + +*W3C Tests XPath Datamodel* + + $ ctest -L "^xpath/test" + [...] + $ 51% tests passed, 104 tests failed out of 211 + +*W3C Tests PROMELA Datamodel* + + $ ctest -L "^promela/test" + [...] + $ 89% tests passed, 18 tests failed out of 165 + +*W3C Tests Lua Datamodel* + + $ ctest -L "^lua/test" + [...] + $ 78% tests passed, 45 tests failed out of 201 + + ### License uSCXML itself is distributed under the Simplified BSD license as in, do not sue us and do diff --git a/src/uscxml/Interpreter.cpp b/src/uscxml/Interpreter.cpp index 58991e5..72232b8 100644 --- a/src/uscxml/Interpreter.cpp +++ b/src/uscxml/Interpreter.cpp @@ -1312,19 +1312,15 @@ void InterpreterImpl::setupDOM() { // normalize document -#if 0 - // make sure every state has an id - Arabica::XPath::NodeSet states; - states.push_back(_xpath.evaluate("//" + _nsInfo.xpathPrefix + "state", _scxml).asNodeSet()); - states.push_back(_xpath.evaluate("//" + _nsInfo.xpathPrefix + "final", _scxml).asNodeSet()); - states.push_back(_xpath.evaluate("//" + _nsInfo.xpathPrefix + "history", _scxml).asNodeSet()); - for (int i = 0; i < states.size(); i++) { - Arabica::DOM::Element stateElem = Arabica::DOM::Element(states[i]); - if (!stateElem.hasAttribute("id")) { - stateElem.setAttribute("id", UUID::getUUID()); - } - } -#endif + // make sure every state has an id - not required per spec, but needed for us + Arabica::XPath::NodeSet states = getAllStates(); + for (int i = 0; i < states.size(); i++) { + Arabica::DOM::Element stateElem = Arabica::DOM::Element(states[i]); + if (!stateElem.hasAttribute("id")) { + stateElem.setAttribute("id", UUID::getUUID()); + } + _cachedStates[ATTR(stateElem, "id")] = stateElem; + } // make sure every invoke has an idlocation or id - actually required! Arabica::XPath::NodeSet invokes = _xpath.evaluate("//" + _nsInfo.xpathPrefix + "invoke", _scxml).asNodeSet(); @@ -1620,39 +1616,36 @@ void InterpreterImpl::receive(const Event& event, bool toFront) { _condVar.notify_all(); } -void InterpreterImpl::internalDoneSend(const Arabica::DOM::Element& state) { +void InterpreterImpl::internalDoneSend(const Arabica::DOM::Element& state, const Arabica::DOM::Element& doneData) { if (!isState(state)) return; - if (parentIsScxmlState(state)) - return; +// if (parentIsScxmlState(state)) +// return; Event event; - Arabica::XPath::NodeSet doneDatas = filterChildElements(_nsInfo.xmlNSPrefix + "donedata", state); - if (doneDatas.size() > 0) { - // only process first donedata element - Arabica::DOM::Element doneData = Element(doneDatas[0]); - processParamChilds(doneData, event.params); - Arabica::XPath::NodeSet contents = filterChildElements(_nsInfo.xmlNSPrefix + "content", doneDatas[0]); - if (contents.size() > 1) - LOG(ERROR) << "Only a single content element is allowed for send elements - using first one"; - if (contents.size() > 0) { - std::string expr; - processContentElement(Element(contents[0]), event.dom, event.content, expr); - if (expr.length() > 0) { - try { - event.content =_dataModel.evalAsString(expr); - } catch (Event e) { - e.name = "error.execution"; - e.dom = contents[0]; - receiveInternal(e); - } - } - } - } - - event.name = "done.state." + ATTR_CAST(state.getParentNode(), "id"); // parent?! + if (doneData) { + processParamChilds(doneData, event.params); + Arabica::XPath::NodeSet contents = filterChildElements(_nsInfo.xmlNSPrefix + "content", doneData); + if (contents.size() > 1) + LOG(ERROR) << "Only a single content element is allowed for send elements - using first one"; + if (contents.size() > 0) { + std::string expr; + processContentElement(Element(contents[0]), event.dom, event.content, expr); + if (expr.length() > 0) { + try { + event.content =_dataModel.evalAsString(expr); + } catch (Event e) { + e.name = "error.execution"; + e.dom = contents[0]; + receiveInternal(e); + } + } + } + } + + event.name = "done.state." + ATTR_CAST(state, "id"); // parent?! receiveInternal(event); } diff --git a/src/uscxml/Interpreter.h b/src/uscxml/Interpreter.h index 5aa4b3f..b6719b5 100644 --- a/src/uscxml/Interpreter.h +++ b/src/uscxml/Interpreter.h @@ -576,7 +576,7 @@ protected: virtual void send(const Arabica::DOM::Element& element); virtual void invoke(const Arabica::DOM::Element& element); virtual void cancelInvoke(const Arabica::DOM::Element& element); - virtual void internalDoneSend(const Arabica::DOM::Element& state); + virtual void internalDoneSend(const Arabica::DOM::Element& state, const Arabica::DOM::Element& doneData); static void delayedSend(void* userdata, std::string eventName); void returnDoneEvent(const Arabica::DOM::Node& state); diff --git a/src/uscxml/interpreter/InterpreterDraft6.cpp b/src/uscxml/interpreter/InterpreterDraft6.cpp index 6bbb7d8..48ba78f 100644 --- a/src/uscxml/interpreter/InterpreterDraft6.cpp +++ b/src/uscxml/interpreter/InterpreterDraft6.cpp @@ -441,7 +441,15 @@ void InterpreterDraft6::enterStates(const Arabica::XPath::NodeSet& } #endif if (isFinal(stateElem)) { - internalDoneSend(stateElem); + + Arabica::DOM::Element doneData; + Arabica::XPath::NodeSet doneDatas = filterChildElements(_nsInfo.xmlNSPrefix + "donedata", stateElem); + if (doneDatas.size() > 0) { + // only process first donedata element + doneData = Element(doneDatas[0]); + } + + internalDoneSend(stateElem, doneData); Node parent = stateElem.getParentNode(); if (parent.getNodeType() == Node_base::ELEMENT_NODE && @@ -458,7 +466,7 @@ void InterpreterDraft6::enterStates(const Arabica::XPath::NodeSet& } } if (inFinalState) { - internalDoneSend(Element(parent)); + internalDoneSend(Element(parent), Arabica::DOM::Element()); } } } diff --git a/src/uscxml/interpreter/InterpreterRC.cpp b/src/uscxml/interpreter/InterpreterRC.cpp index 0237618..b933993 100644 --- a/src/uscxml/interpreter/InterpreterRC.cpp +++ b/src/uscxml/interpreter/InterpreterRC.cpp @@ -295,14 +295,22 @@ void InterpreterRC::enterStates(const Arabica::XPath::NodeSet& enab } if (isFinal(s)) { - internalDoneSend(s); - if (parentIsScxmlState(s)) { + Element parent = (Element)s.getParentNode(); + + Arabica::DOM::Element doneData; + Arabica::XPath::NodeSet doneDatas = filterChildElements(_nsInfo.xmlNSPrefix + "donedata", s); + if (doneDatas.size() > 0) { + // only process first donedata element + doneData = Element(doneDatas[0]); + } + internalDoneSend(parent, doneData); + + if (parentIsScxmlState(s)) { _topLevelFinalReached = true; } else { - Element parent = (Element)s.getParentNode(); Element grandParent = (Element)parent.getParentNode(); - internalDoneSend(parent); +// internalDoneSend(parent, Arabica::DOM::Element()); if (isParallel(grandParent)) { Arabica::XPath::NodeSet childs = getChildStates(grandParent); @@ -314,7 +322,7 @@ void InterpreterRC::enterStates(const Arabica::XPath::NodeSet& enab } } if (inFinalState) { - internalDoneSend(grandParent); + internalDoneSend(grandParent, Arabica::DOM::Element()); } } } diff --git a/src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.cpp b/src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.cpp index f6131f8..21b390a 100644 --- a/src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.cpp +++ b/src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.cpp @@ -689,7 +689,9 @@ bool SWIDataModel::evalAsBool(const Arabica::DOM::Element& node, co } PlQuery query(compound.name(), termv); return query.next_solution() > 0; - } catch(...) { + } + RETHROW_PLEX_AS_EVENT + catch(...) { return false; } } @@ -823,7 +825,7 @@ void SWIDataModel::assign(const Element& assignElem, PlCall(dataInitStr.str().c_str()); } else { // treat content as . seperated facts - std::stringstream factStream(content); + std::stringstream factStream(expr); std::string item; while(std::getline(factStream, item, '.')) { std::string fact = boost::trim_copy(item); diff --git a/src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.new b/src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.new new file mode 100644 index 0000000..8238577 --- /dev/null +++ b/src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.new @@ -0,0 +1,962 @@ +/** + * @file + * @author 2012-2013 Stefan Radomski (stefan.radomski@cs.tu-darmstadt.de) + * @copyright Simplified BSD + * + * @cond + * This program is free software: you can redistribute it and/or modify + * it under the terms of the FreeBSD license as published by the FreeBSD + * project. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * + * You should have received a copy of the FreeBSD license along with this + * program. If not, see . + * @endcond + */ + +#include + +#include "uscxml/Common.h" +#include "uscxml/config.h" +#include "SWIDataModel.h" +#include "uscxml/DOMUtils.h" +#include "uscxml/Message.h" +#include + +#ifdef BUILD_AS_PLUGINS +#include +#endif + +// these are defined but not exported by swi-prolog 7 +extern "C" { + PL_EXPORT(int) PL_is_dict(term_t t); + PL_EXPORT(int) PL_for_dict(term_t dict, int (*func)(term_t key, term_t value, int last, void *closure), void *closure, int flags); +} +#define RETHROW_PLEX_AS_EVENT \ +catch (PlException plex) { \ + ERROR_EXECUTION_THROW((char*)plex); \ +} \ + +#define PL_MODULE \ +_interpreter.getSessionId().c_str() \ + +#define SET_PL_ENGINE(dm) \ +assert(_swiEngines.find(dm) != _swiEngines.end()); \ +int rc = PL_set_engine(_swiEngines[dm], NULL); \ +assert(rc == PL_ENGINE_SET); \ +_dmPtr = dm; + +namespace uscxml { + +using namespace Arabica::XPath; +using namespace Arabica::DOM; + +#ifdef BUILD_AS_PLUGINS +PLUMA_CONNECTOR +bool pluginConnect(pluma::Host& host) { + host.add( new SWIDataModelProvider() ); + return true; +} +#endif + +// SWI prolog does not support passing user data +static SWIDataModel* _dmPtr; +static std::map _swiEngines; + +PL_blob_t SWIDataModel::blobType = { + PL_BLOB_MAGIC, + PL_BLOB_NOCOPY, + (char*)"blob", + releaseBlob, + compareBlob, + writeBlob, + acquireBlob +}; + +SWIDataModel::SWIDataModel() { +} + +SWIDataModel::~SWIDataModel() { + try { + if (_swiEngines.find(this) != _swiEngines.end()) { + PL_destroy_engine(_swiEngines[this]); + _swiEngines.erase(this); + } + } + RETHROW_PLEX_AS_EVENT; +} + +boost::shared_ptr SWIDataModel::create(InterpreterImpl* interpreter) { + try { + boost::shared_ptr dm = boost::shared_ptr(new SWIDataModel()); + dm->_interpreter = interpreter; + + const char* swibin = getenv("SWI_BINARY"); + if (swibin == NULL) + swibin = SWI_BINARY; + const char* quiet = "--quiet"; + + int argc = 2; + static char * av[] = { + (char*)swibin, + (char*)quiet, + NULL + }; + + if (!PL_is_initialised(NULL, NULL)) { + if(!PL_initialise(argc,av)) { + LOG(ERROR) << "Error intializing prolog engine"; + PL_halt(1); + return boost::shared_ptr(); + } + + PL_set_engine(PL_ENGINE_CURRENT, &_engine); + + // load SWI XML parser + try { + PlCall("use_module", PlCompound("library", PlTerm("sgml"))); + } catch (PlException plex) { + + LOG(ERROR) << "Cannot load prolog sgml module - make sure you have it installed in your prolog runtime: " << (char*)plex; + throw plex; + } + + // load json parser + try { + PlCall("use_module", PlCompound("library", PlTerm("http/json"))); + PlCall("use_module", PlCompound("library", PlTerm("http/json_convert"))); + } catch (PlException plex) { + LOG(ERROR) << "Cannot load prolog json module or json_convert - make sure you have it installed in your prolog runtime: " << (char*)plex; + throw plex; + } + + } else { + LOG(WARNING) << "Instantiating more than one SWI prolog datamodel will lead to weird effects as I cannot seperate the environments"; +// engine = PL_create_engine(NULL); + } + +// assert(engine); +// _swiEngines[dm.get()] = engine; + _dmPtr = dm.get(); + +// int rc = PL_set_engine(engine, NULL); +// assert(rc == PL_ENGINE_SET); +// (void)rc; + + _plModule = boost::replace_all_copy(interpreter->getSessionId(), "-", ""); + boost::replace_all(_plModule, "0", "g"); + boost::replace_all(_plModule, "1", "h"); + boost::replace_all(_plModule, "2", "i"); + boost::replace_all(_plModule, "3", "j"); + boost::replace_all(_plModule, "4", "k"); + boost::replace_all(_plModule, "5", "l"); + boost::replace_all(_plModule, "6", "m"); + boost::replace_all(_plModule, "7", "n"); + boost::replace_all(_plModule, "8", "o"); + boost::replace_all(_plModule, "9", "p"); + + // use atoms for double quoted + PlCall("set_prolog_flag(double_quotes,atom)."); + + // set system variables + PlCall("assert", PlCompound("sessionid", PlTerm(PlString(dm->_interpreter->getSessionId().c_str())))); + PlCall("assert", PlCompound("name", PlTerm(PlString(dm->_interpreter->getName().c_str())))); + + std::map::const_iterator ioProcIter = dm->_interpreter->getIOProcessors().begin(); + while(ioProcIter != dm->_interpreter->getIOProcessors().end()) { + Data ioProcData = ioProcIter->second.getDataModelVariables(); + + if (ioProcIter->first.find_first_of(":/'") == std::string::npos) { + std::stringstream ioProcShortCall; + ioProcShortCall << "assert(ioprocessors(" << ioProcIter->first << "(location('" << ioProcData.compound["location"].atom << "'))))"; + PlCall(ioProcShortCall.str().c_str()); + } + std::stringstream ioProcCall; + ioProcCall << "assert(ioprocessors(name('" << ioProcIter->first << "'), location('" << ioProcData.compound["location"].atom << "')))"; + PlCall(ioProcCall.str().c_str()); + + ioProcIter++; + } + + // the in predicate + PlRegister("user", "in", 1, SWIDataModel::inPredicate); + PL_set_engine(NULL, NULL); + return dm; + } + RETHROW_PLEX_AS_EVENT; +} + +foreign_t SWIDataModel::inPredicate(term_t a0, int arity, void* context) { + try { + char *s; + if ( PL_get_atom_chars(a0, &s) ) { + if (_dmPtr->_interpreter->isInState(s)) { + return true; + } + } + return FALSE; + } + RETHROW_PLEX_AS_EVENT; +} + +void SWIDataModel::registerIOProcessor(const std::string& name, const IOProcessor& ioprocessor) { +// std::cout << "SWIDataModel::registerIOProcessor" << std::endl; +} + +void SWIDataModel::setSessionId(const std::string& sessionId) { +// std::cout << "SWIDataModel::setSessionId" << std::endl; + _sessionId = sessionId; +} + +void SWIDataModel::setName(const std::string& name) { +// std::cout << "SWIDataModel::setName" << std::endl; + _name = name; +} + +void SWIDataModel::pushContext() { +// std::cout << "SWIDataModel::pushContext" << std::endl; +} + +void SWIDataModel::popContext() { +// std::cout << "SWIDataModel::popContext" << std::endl; +} + +void SWIDataModel::initialize() { +// std::cout << "SWIDataModel::initialize" << std::endl; +} + +void SWIDataModel::setEvent(const Event& event) { + SWIEngineLock engineLock; + + // remove old event + try { + PlCall("retractall(event(_))"); + + // simple values + PlCall("assert", PlCompound("event", PlCompound("name", PlTerm(event.name.c_str())))); + PlCall("assert", PlCompound("event", PlCompound("origin", PlString(event.origin.c_str())))); + PlCall("assert", PlCompound("event", PlCompound("origintype", PlString(event.invokeid.c_str())))); + PlCall("assert", PlCompound("event", PlCompound("invokeid", PlTerm(event.origintype.c_str())))); + PlCall("assert", PlCompound("event", PlCompound("raw", PlString(event.raw.c_str())))); + + // event.type + std::string type; + switch (event.eventType) { + case Event::PLATFORM: + type = "platform"; + break; + case Event::INTERNAL: + type = "internal"; + break; + case Event::EXTERNAL: + type = "external"; + break; + } + PlCall("assert", PlCompound("event", PlCompound("type", PlTerm(type.c_str())))); + + // event.sendid + if (!event.hideSendId) + PlCall("assert", PlCompound("event", PlCompound("sendid", PlTerm(event.sendid.c_str())))); + + // event.data + URL domUrl; + if (event.dom) { + std::stringstream dataInitStr; + std::stringstream xmlDoc; +// xmlDoc << event.getFirstDOMElement(); + xmlDoc << event.dom; + domUrl = URL::toLocalFile(xmlDoc.str(), ".pl"); + dataInitStr << "load_xml_file('" << domUrl.asLocalFile(".pl") << "', XML), copy_term(XML,DATA), assert(event(data(DATA)))"; + PlCall(dataInitStr.str().c_str()); + } else if (event.content.size() > 0) { + PlCall("assert", PlCompound("event", PlCompound("data", PlString(InterpreterImpl::spaceNormalize(event.content).c_str())))); + } else if (!event.data.empty()) { + assertFromData(event.data, "event(data(", 2); + } + + Event::params_t::const_iterator paramIter = event.params.begin(); + while(paramIter != event.params.end()) { + assertFromData(paramIter->second, "event(param(" + paramIter->first + "(", 3); + paramIter++; + } + + Event::namelist_t::const_iterator namelistIter = event.namelist.begin(); + while(namelistIter != event.namelist.end()) { + assertFromData(paramIter->second, "event(param(" + namelistIter->first + "(", 3); + namelistIter++; + } + +#if 0 + // event.params + size_t uniqueKeys = 0; + Event::params_t::const_iterator paramIter = event.params.begin(); + while(paramIter != event.params.end()) { + uniqueKeys++; + paramIter = event.params.upper_bound(paramIter->first); + } + if (uniqueKeys > 0) { + paramIter = event.params.begin(); + for(int i = 0; paramIter != event.params.end(); i++) { + std::stringstream paramArray; + Event::params_t::const_iterator lastValueIter = event.params.upper_bound(paramIter->first); + + paramArray << paramIter->first << "(["; + std::string termSep = ""; + + for (int j = 0; paramIter != lastValueIter; j++) { + paramArray << termSep << "'" << paramIter->second << "'"; + termSep = ", "; + paramIter++; + } + paramArray << "])"; + std::stringstream paramExpr; + paramExpr << "assert(event(param(" << paramArray.str() << ")))"; + //std::cout << paramExpr.str() << std::endl; + PlCall(paramExpr.str().c_str()); + + paramIter = lastValueIter; + } + } +#endif + } + RETHROW_PLEX_AS_EVENT; +} + +void SWIDataModel::assertFromData(const Data& data, const std::string& expr, size_t nesting) { + if (data.atom.size() > 0) { + // terminal branch, this is where we assert + + std::stringstream ss; + ss << expr; +// nesting++; + + if (data.type == Data::VERBATIM) { + ss << "\"" << data.atom << "\""; + } else { + ss << data.atom; + } + + for (size_t i = 0; i < nesting; i++) { + ss << ")"; + } + +// std::cout << ss.str() << std::endl; + PlCall("assert", PlCompound(ss.str().c_str())); + return; + } + + if (data.compound.size() > 0) { + std::map::const_iterator compIter = data.compound.begin(); + while(compIter != data.compound.end()) { +// std::cout << compIter->first << std::endl; + std::stringstream prefix; + size_t prefixNesting = 0; + size_t oldPos = 0; + size_t pos = 0; + while((pos = compIter->first.find_first_of(",.(-", oldPos)) != std::string::npos) { + prefix << compIter->first.substr(oldPos, pos - oldPos) << "("; + prefixNesting++; + oldPos = pos + 1; + } + if (oldPos != compIter->first.size()) { + prefix << compIter->first.substr(oldPos, compIter->first.size() - oldPos) << "("; + prefixNesting++; + } + assertFromData(compIter->second, expr + prefix.str(), nesting + prefixNesting); + compIter++; + } + } + + if (data.array.size() > 0) { + std::list::const_iterator arrIter = data.array.begin(); + while(arrIter != data.array.end()) { + assertFromData(*arrIter, expr, nesting); + arrIter++; + } + } + + if (data.node) { + std::stringstream dataInitStr; + std::stringstream xmlDoc; + + xmlDoc << data.node; + URL domUrl = URL::toLocalFile(xmlDoc.str(), ".pl"); + dataInitStr << "load_xml_file('" << domUrl.asLocalFile(".pl") << "', XML), "; + dataInitStr << "copy_term(XML,DATA), "; + dataInitStr << "assert("; + dataInitStr << expr << "(DATA)"; + + for (size_t i = 0; i < nesting; i++) { + dataInitStr << ")"; + } + + PlCall(dataInitStr.str().c_str()); + return; + } +} + +#if 0 +std::list SWIDataModel::getSolutions(PlCompound compound) { + std::list solutions; + + PlTermv termv(compound.arity()); + for (int i = 0; i < compound.arity(); i++) { + termv[i] = compound[i + 1]; + } + PlQuery query(compound.name(), termv); + while(query.next_solution()) { +// std::cout << (char*)compound << std::endl; + solutions.push_back(compound); + } + return solutions; +} +#endif + +Data SWIDataModel::getStringAsData(const std::string& content) { + SWIEngineLock engineLock; + try { + PlCompound compound(content.c_str()); + PlCompound orig(content.c_str()); + Data data; + + PlTermv termv(compound.arity()); + for (int i = 0; i < compound.arity(); i++) { + termv[i] = compound[i + 1]; + } + PlQuery query(compound.name(), termv); + + while(query.next_solution()) { + std::map vars = resolveAtoms(compound, orig); + std::map::const_iterator varIter = vars.begin(); + + while(varIter != vars.end()) { + data.merge(termAsData(varIter->second)); + varIter++; + } + + } +// std::cout << Data::toJSON(data) << std::endl; + return data; + } catch (PlException plex) { + try { + // could not parse as compound, try term and type in termAsData + PlTerm term(content.c_str()); + return(termAsData(term)); + } + RETHROW_PLEX_AS_EVENT + } + return Data(); +} + +Data SWIDataModel::termAsData(PlTerm term) { + + Data data; +// std::cout << term.name() << (char*)term << std::endl; + + switch (term.type()) { + case PL_TERM: + for (int i = 1; i <= term.arity(); i++) { // arguments start at 1 + data.compound[term.name()] = termAsData(term[i]); + } + break; + case PL_VARIABLE: + case PL_INTEGER: + case PL_FLOAT: + case PL_SHORT: + case PL_INT: + case PL_LONG: + case PL_DOUBLE: + data.atom = std::string(term); + data.type = Data::INTERPRETED; + break; + case PL_STRING: + case PL_ATOM: + data.atom = std::string(term); + data.type = Data::VERBATIM; + break; +#ifdef SWI_HAS_PL_NIL + case PL_NIL: + data.array.push_back(Data("", Data::VERBATIM)); + break; +#endif +#ifdef SWI_HAS_PL_LIST_PAIR + case PL_LIST_PAIR: { + PlTail tail(term); + PlTerm item; + while(tail.next(item)) { + data.array.push_back(termAsData(item)); + } + break; + } +#endif +#ifdef SWI_HAS_DICT + case PL_DICT: { + std::string key(term); + size_t curlyPos = key.find_first_of("{"); + if (curlyPos == std::string::npos || curlyPos == 0) { + // no key given + PL_for_dict(term, SWIDataModel::dictCallBack, &data, 0); + } else { + // with key given + Data& tmp = data.compound[boost::trim_copy(key.substr(0, curlyPos))]; + PL_for_dict(term, SWIDataModel::dictCallBack, &tmp, 0); + } + break; + } +#endif + default: + LOG(ERROR) << "Prolog type " << term.type() << " at '" << (char*)term << "' not supported"; + break; + } + return data; +} + +int SWIDataModel::dictCallBack(term_t key, term_t value, int last, void *closure) { + Data* data = (Data*)closure; + PlTerm keyTerm(key); + data->compound[(char*)keyTerm] = termAsData(value); + return 0; +} + +PlTerm SWIDataModel::dataAsTerm(Data data) { + if (data.atom.length() > 0) { + return PlTerm(data.atom.c_str()); + } + if (data.array.size() > 0) { + PlTerm head; + PlTail list(head); + + std::list::const_iterator arrIter = data.array.begin(); + while(arrIter != data.array.end()) { + list.append(dataAsTerm(*arrIter)); + arrIter++; + } + list.close(); + return PlTail(head); + } + if (data.compound.size() > 0) { + if (data.compound.size() == 1 && data.compound.begin()->second.array.size() > 0) { + // this used to be a prolog compound + const Data& arr = data.compound.begin()->second; + PlTermv termv(arr.array.size()); + int index = 0; + + std::list::const_iterator arrIter = arr.array.begin(); + while(arrIter != arr.array.end()) { + termv[index] = dataAsTerm(*arrIter); + index++; + arrIter++; + } + return PlCompound(data.compound.begin()->first.c_str(), termv); + } else if (data.compound.size() == 1 && data.compound.begin()->second.compound.size() > 0) { + // this used to be a named dict - until we have dict support in C/C++ use PL_chars_to_term + std::stringstream dictSS; + std::string seperator; + dictSS << data.compound.begin()->first << "{"; + + std::map::const_iterator keyIter = data.compound.begin()->second.compound.begin(); + while(keyIter != data.compound.begin()->second.compound.end()) { + dictSS << seperator << keyIter->first << ":" << (char*)dataAsTerm(keyIter->second); + seperator = ","; + keyIter++; + } + dictSS << "}"; + return PlCompound(dictSS.str().c_str()); + + } else { + // an array of dicts + PlTermv termv(data.compound.size()); + int index = 0; + + std::map::const_iterator compIter = data.compound.begin(); + while(compIter != data.compound.end()) { + termv[index] = PlCompound(compIter->first.c_str(), dataAsTerm(compIter->second)); + index++; + compIter++; + } + return PlCompound(data.compound.begin()->first.c_str(), termv); + + } + } + if (data.binary) { + LOG(ERROR) << "Binary data with prolog datamodel still very experimental"; +// term_t binTerm = PL_new_term_ref(); +// PL_put_blob(binTerm, data.binary->data, data.binary->size, &blobType); +// return binTerm; + } + if (data.node) { + LOG(ERROR) << "DOM in event with prolog datamodel still very experimental"; + std::stringstream dataInitStr; + std::stringstream xmlDoc; + // xmlDoc << event.getFirstDOMElement(); + xmlDoc << data.node; + URL domUrl = URL::toLocalFile(xmlDoc.str(), ".pl"); + dataInitStr << "load_xml_file('" << domUrl.asLocalFile(".pl") << "', XML), copy_term(XML,DATA), assert(event(data(DATA)))"; + PlCall(dataInitStr.str().c_str()); + } + + return PlTerm(); +} + +bool SWIDataModel::validate(const std::string& location, const std::string& schema) { + SWIEngineLock engineLock; +// std::cout << "SWIDataModel::validate" << std::endl; + return true; +} + +bool SWIDataModel::isLocation(const std::string& expr) { + return true; +} + +uint32_t SWIDataModel::getLength(const std::string& expr) { + SWIEngineLock engineLock; + try { + PlCompound compound(expr.c_str()); + PlTermv termv(compound.arity()); + for (int i = 0; i < compound.arity(); i++) { + termv[i] = compound[i + 1]; + } + PlQuery query(compound.name(), termv); + uint32_t length = 0; + while(query.next_solution() > 0) + length++; + return length; + } + RETHROW_PLEX_AS_EVENT; +} + +void SWIDataModel::setForeach(const std::string& item, + const std::string& array, + const std::string& index, + uint32_t iteration) { + SWIEngineLock engineLock; + try { + PlCompound compound(array.c_str()); + PlCompound orig(array.c_str()); + PlTermv termv(compound.arity()); + for (int i = 0; i < compound.arity(); i++) { + termv[i] = compound[i + 1]; + } + { + int tmp = iteration + 1; + PlQuery query(compound.name(), termv); + while (tmp) { + query.next_solution(); + tmp--; + } + } + PlCall("retractall", PlCompound(index.c_str(), 1)); + PlCall("retractall", PlCompound(item.c_str(), 1)); + PlCall("assert", PlCompound(index.c_str(), PlTerm((long)iteration))); + + std::map vars = resolveAtoms(compound, orig); + std::map::iterator varIter = vars.begin(); + while(varIter != vars.end()) { + PlCall("assert", PlCompound(item.c_str(), varIter->second)); + varIter++; + } + } + RETHROW_PLEX_AS_EVENT; +} + +void SWIDataModel::eval(const Element& scriptElem, const std::string& expr) { + SWIEngineLock engineLock; + try { + if (scriptElem && HAS_ATTR(scriptElem, "type") && iequals(ATTR(scriptElem, "type"), "query")) { + evalAsBool(expr); + } else { + URL localPLFile = URL::toLocalFile(expr, ".pl"); + PlCall("user", "load_files", PlTermv(localPLFile.asLocalFile(".pl").c_str())) || LOG(ERROR) << "Could not execute prolog from file"; + } + } + RETHROW_PLEX_AS_EVENT; +} + +bool SWIDataModel::evalAsBool(const std::string& expr) { + return evalAsBool(Arabica::DOM::Element(), expr); +} + +bool SWIDataModel::evalAsBool(const Arabica::DOM::Element& node, const std::string& expr) { + SWIEngineLock engineLock; + try { + PlCompound compound(expr.c_str()); + PlTermv termv(compound.arity()); + for (int i = 0; i < compound.arity(); i++) { + termv[i] = compound[i + 1]; + } + PlQuery query(compound.name(), termv); + return query.next_solution() > 0; + } + RETHROW_PLEX_AS_EVENT + catch(...) { + return false; + } +} + +std::string SWIDataModel::evalAsString(const std::string& expr) { + SWIEngineLock engineLock; + try { + + PlCompound compound(expr.c_str()); + + if (strlen(compound.name())) { + PlCompound orig(expr.c_str()); + + PlTermv termv(compound.arity()); + for (int i = 0; i < compound.arity(); i++) { + termv[i] = compound[i + 1]; + } + PlQuery query(compound.name(), termv); + + std::stringstream ss; + std::string solSeparator = ""; + while (query.next_solution()) { + ss << solSeparator; + std::map vars = resolveAtoms(compound, orig); + std::map::const_iterator varIter = vars.begin(); + + std::string varSeparator = ""; + while(varIter != vars.end()) { + ss << varSeparator << (char *)varIter->second; + varSeparator = ", "; + varIter++; + } + solSeparator = "\n"; + } + return ss.str(); + } + return std::string(compound); + + } catch(PlException plex) { + // we got an exception while trying to evaluate as compound + PlTerm term(expr.c_str()); + if (term.type() == PL_ATOM || term.type() == PL_CHARS || term.type() == PL_STRING) { + return std::string(term); + } else { + ERROR_EXECUTION_THROW((char*)plex); + } + } +} + + +// this is similar to http://etalis.googlecode.com/svn/eEtalis/src/term.c +std::map SWIDataModel::resolveAtoms(PlTerm& term, PlTerm& orig) { + try { + std::map atoms; + switch (orig.type()) { + case PL_VARIABLE: { + atoms[(char *)orig] = term; + break; + } + case PL_ATOM: + break; + case PL_STRING: + break; + case PL_INTEGER: + break; + case PL_TERM: + for (int i = 1; i <= orig.arity(); i++) { + PlTerm newTerm = term[i]; + PlTerm newOrig = orig[i]; + std::map result = resolveAtoms(newTerm, newOrig); + atoms.insert(result.begin(), result.end()); + } + break; + default: + LOG(ERROR) << "Resolving variable of unknown type in query solution"; + } + return atoms; + } + RETHROW_PLEX_AS_EVENT +} + +void SWIDataModel::assign(const Element& assignElem, + const Node& node, + const std::string& content) { + SWIEngineLock engineLock; + try { + std::string callAssert = "assert"; + std::string solution; + std::string expr = content; + std::string predicate; + if (HAS_ATTR(assignElem, "solution")) + solution = ATTR(assignElem, "solution"); + if (HAS_ATTR(assignElem, "expr")) + expr = ATTR(assignElem, "expr"); + if (HAS_ATTR(assignElem, "id")) + predicate = ATTR(assignElem, "id"); + if (HAS_ATTR(assignElem, "location")) + predicate = ATTR(assignElem, "location"); + + if (solution.size() > 0 && expr.size() > 0 && predicate.size() > 0) { + // + std::cout << expr + ", " + callAssert + "(" + predicate + "(" + solution + "))" << std::endl; + PlCall((expr + ", " + callAssert + "(" + predicate + "(" + solution + "))").c_str()); + return; + } + + if (expr.size() > 0 && predicate.size()) { + Data json = Data::fromJSON(expr); + if (!json.empty()) { + std::cout << callAssert + "(" + predicate + ")" << std::endl; + PlCall((callAssert + "(" + predicate + ")").c_str()); + // expression is a JSON structure! + std::stringstream dataInitStr; + // if (iequals(type, "retract")) + // PlCall("retractall", PlCompound(predicate.c_str(), 1)); + dataInitStr << "json_to_prolog(" << expr << ", JSON), assert(" << predicate << "(JSON))"; + PlCall(dataInitStr.str().c_str()); + return; + } + } + + if (expr.size() > 0 && predicate.size()) { + // treat content as . seperated facts + std::stringstream factStream(expr); + std::string item; + while(std::getline(factStream, item, '.')) { + std::string fact = boost::trim_copy(item); + if (fact.length() == 0) + continue; + std::cout << callAssert + "(" + predicate + "(" + fact + "))" << std::endl; + PlCall((callAssert + "(" + predicate + "(" + fact + "))").c_str()); + } + return; + } + + if (predicate.size() > 0) { + std::cout << callAssert + "(" + predicate + ")" << std::endl; + PlCall((callAssert + "(" + predicate + ")").c_str()); + return; + } + + abort(); + + if (expr.size() == 0) { + // no expression, just assert id or idlocation + std::cout << callAssert + "(" + predicate + ")" << std::endl; + PlCall((callAssert + "(" + predicate + ")").c_str()); + return; + } + + + std::cout << expr + ", " + callAssert + "(" + predicate + ")" << std::endl; + PlCall((expr + ", " + callAssert + "(" + predicate + ")").c_str()); + + + } +#if 0 + try { + std::string expr = content; + std::string predicate; + if (HAS_ATTR(assignElem, "expr")) { + expr = ATTR(assignElem, "expr"); + } + if (HAS_ATTR(assignElem, "id")) + predicate = ATTR(assignElem, "id"); + if (HAS_ATTR(assignElem, "location")) + predicate = ATTR(assignElem, "location"); + + if (predicate.size() > 0) { + std::string callAssert = "assert"; + std::string type; + if (HAS_ATTR(assignElem, "type")) { + type = ATTR(assignElem, "type"); + if(iequals(type, "append")) { + callAssert = "assertz"; + } else if(iequals(type, "prepend")) { + callAssert = "asserta"; + } + } + + URL domUrl; + Data json; + if (!node) + json = Data::fromJSON(expr); + if (node) { + std::stringstream dataInitStr; + std::stringstream xmlDoc; + Node child = node; + while(child) { + xmlDoc << child; + child = child.getNextSibling(); + } + domUrl = URL::toLocalFile(xmlDoc.str(), ".pl"); + if (iequals(type, "retract")) + PlCall("retractall", PlCompound(predicate.c_str(), 1)); + dataInitStr << "load_xml_file('" << domUrl.asLocalFile(".pl") << "', XML), copy_term(XML,DATA), " << callAssert << "(" << predicate << "(DATA))"; + PlCall(dataInitStr.str().c_str()); + } else if (!json.empty()) { + std::stringstream dataInitStr; + if (iequals(type, "retract")) + PlCall("retractall", PlCompound(predicate.c_str(), 1)); + dataInitStr << "json_to_prolog(" << expr << ", JSON), assert(" << predicate << "(JSON))"; + PlCall(dataInitStr.str().c_str()); + } else { + // treat content as . seperated facts + std::stringstream factStream(content); + std::string item; + while(std::getline(factStream, item, '.')) { + std::string fact = boost::trim_copy(item); + if (fact.length() == 0) + continue; + PlCall((callAssert + "(" + predicate + "(" + fact + "))").c_str()); + } + } + } else if (expr.length() > 0) { + if (boost::equals(TAGNAME(assignElem), "data")) { + eval(assignElem, expr); + } else { + std::stringstream exprStream(expr); + std::string item; + while(std::getline(exprStream, item, '.')) { + std::string plExpr = boost::trim_copy(item); + if (plExpr.length() == 0) + continue; + PlCall(plExpr.c_str()); + } + } + } + } +#endif + RETHROW_PLEX_AS_EVENT +} + +void SWIDataModel::assign(const std::string& location, const Data& data) { + eval(Element(), data.atom); +} + +void SWIDataModel::init(const Element& dataElem, + const Node& node, + const std::string& content) { + assign(dataElem, node, content); +} +void SWIDataModel::init(const std::string& location, const Data& data) { + assign(location, data); +} + +bool SWIDataModel::isDeclared(const std::string& expr) { + return true; +} + +void SWIDataModel::acquireBlob(atom_t symbol) { +} + + +int SWIDataModel::releaseBlob(atom_t symbol) { + return TRUE; +} + +int SWIDataModel::compareBlob(atom_t a, atom_t b) { + return 0; +} + +int SWIDataModel::writeBlob(void *s, atom_t symbol, int flags) { + return TRUE; +} + + +} diff --git a/src/uscxml/server/HTTPServer.cpp b/src/uscxml/server/HTTPServer.cpp index f6c1f2e..57c1e4f 100644 --- a/src/uscxml/server/HTTPServer.cpp +++ b/src/uscxml/server/HTTPServer.cpp @@ -594,7 +594,7 @@ bool HTTPServer::registerServlet(const std::string& path, HTTPServlet* servlet) servlet->setURL(servletURL.str()); INSTANCE->_httpServlets[suffixedPath] = servlet; - LOG(INFO) << "HTTP Servlet listening at: " << servletURL.str() << std::endl; + DLOG(INFO) << "HTTP Servlet listening at: " << servletURL.str() << std::endl; // register callback evhttp_set_cb(INSTANCE->_http, ("/" + suffixedPath).c_str(), HTTPServer::httpRecvReqCallback, servlet); diff --git a/src/uscxml/transform/ChartToFSM.cpp b/src/uscxml/transform/ChartToFSM.cpp index ef59d84..fd7491c 100644 --- a/src/uscxml/transform/ChartToFSM.cpp +++ b/src/uscxml/transform/ChartToFSM.cpp @@ -412,12 +412,12 @@ void ChartToFSM::cancelInvoke(const Arabica::DOM::Element& element) _currGlobalTransition->hasExecutableContent = true; } -void ChartToFSM::internalDoneSend(const Arabica::DOM::Element& state) { +void ChartToFSM::internalDoneSend(const Arabica::DOM::Element& state, const Arabica::DOM::Element& doneData) { if (!isState(state)) return; - if (parentIsScxmlState(state)) - return; +// if (parentIsScxmlState(state)) +// return; // return; // std::cerr << "internalDoneSend: " << state << std::endl; @@ -431,22 +431,21 @@ void ChartToFSM::internalDoneSend(const Arabica::DOM::Element& stat onentry.appendChild(raise); - Arabica::XPath::NodeSet doneDatas = filterChildElements(_nsInfo.xmlNSPrefix + "donedata", state); - if (doneDatas.size() > 0) { - Arabica::DOM::Node doneData = doneDatas[0]; - Arabica::XPath::NodeSet contents = filterChildElements(_nsInfo.xmlNSPrefix + "content", doneDatas[0]); - if (contents.size() > 0) { - Node imported = _flatDoc.importNode(contents[0], true); - raise.appendChild(imported); - } - Arabica::XPath::NodeSet params = filterChildElements(_nsInfo.xmlNSPrefix + "param", doneDatas[0]); - if (params.size() > 0) { - Node imported = _flatDoc.importNode(params[0], true); - raise.appendChild(imported); - } - } + if (doneData) { + Arabica::XPath::NodeSet contents = filterChildElements(_nsInfo.xmlNSPrefix + "content", doneData); + if (contents.size() > 0) { + Node imported = _flatDoc.importNode(contents[0], true); + raise.appendChild(imported); + } + Arabica::XPath::NodeSet params = filterChildElements(_nsInfo.xmlNSPrefix + "param", doneData); + if (params.size() > 0) { + Node imported = _flatDoc.importNode(params[0], true); + raise.appendChild(imported); + } + } + - raise.setAttribute("event", "done.state." + ATTR_CAST(state.getParentNode(), "id")); // parent?! + raise.setAttribute("event", "done.state." + ATTR_CAST(state, "id")); // parent?! GlobalTransition::Action action; action.raiseDone = onentry; // HERE! diff --git a/src/uscxml/transform/ChartToFSM.h b/src/uscxml/transform/ChartToFSM.h index 9d1ed97..64d1a0c 100644 --- a/src/uscxml/transform/ChartToFSM.h +++ b/src/uscxml/transform/ChartToFSM.h @@ -276,7 +276,7 @@ private: // override to do nothing void send(const Arabica::DOM::Element& element) {} - void internalDoneSend(const Arabica::DOM::Element& state); + void internalDoneSend(const Arabica::DOM::Element& state, const Arabica::DOM::Element& doneData); // InterpreterMonitor virtual void beforeMicroStep(Interpreter interpreter); diff --git a/src/uscxml/transform/ChartToFlatSCXML.h b/src/uscxml/transform/ChartToFlatSCXML.h index f611a7c..7afe3c5 100644 --- a/src/uscxml/transform/ChartToFlatSCXML.h +++ b/src/uscxml/transform/ChartToFlatSCXML.h @@ -33,7 +33,9 @@ public: operator Interpreter(); Arabica::DOM::Document getDocument() const { - return _flatDoc; + if (_flatDoc) + return _flatDoc; + return _document; } protected: diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 3ea960c..f9890da 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -36,6 +36,7 @@ endif() USCXML_TEST_COMPILE(BUILD_ONLY NAME test-sockets LABEL general/test-sockets FILES src/test-sockets.cpp) USCXML_TEST_COMPILE(NAME test-url LABEL general/test-url FILES src/test-url.cpp) +USCXML_TEST_COMPILE(NAME test-doneevent LABEL general/test-doneevent FILES src/test-doneevent.cpp) USCXML_TEST_COMPILE(NAME test-base64 LABEL general/test-base64 FILES src/test-base64.cpp) USCXML_TEST_COMPILE(NAME test-eventdelay LABEL general/test-eventdelay FILES src/test-eventdelay.cpp) USCXML_TEST_COMPILE(NAME test-flat-stateid LABEL general/test-flat-stateid FILES src/test-flat-stateid.cpp) @@ -74,6 +75,9 @@ find_program(SPIN spin) find_program(GCC gcc) if (NOT BUILD_MINIMAL) + # compile and add all reported issues tests + + add_executable(test-w3c src/test-w3c.cpp) target_link_libraries(test-w3c uscxml uscxml_transform) set_target_properties(test-w3c PROPERTIES FOLDER "Tests") @@ -169,6 +173,12 @@ if (NOT BUILD_MINIMAL) set_property(TEST ${TEST_NAME} PROPERTY LABELS ${TEST_NAME}) # set_tests_properties(${TEST_NAME} PROPERTIES FAIL_REGULAR_EXPRESSION "TEST FAILED") endif() + + if (BUILD_DM_PROLOG AND SWI_FOUND AND BUILD_TESTS_W3C_PROLOG AND TEST_NAME MATCHES "^prolog\\/.*") + add_test(${TEST_NAME} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/test-w3c ${W3C_TEST}) + set_property(TEST ${TEST_NAME} PROPERTY LABELS ${TEST_NAME}) + # set_tests_properties(${TEST_NAME} PROPERTIES FAIL_REGULAR_EXPRESSION "TEST FAILED") + endif() if (BUILD_DM_PROMELA AND BUILD_TESTS_W3C_PROMELA AND TEST_NAME MATCHES "^promela\\/.*") add_test(${TEST_NAME} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/test-w3c ${W3C_TEST}) diff --git a/test/src/test-doneevent.cpp b/test/src/test-doneevent.cpp new file mode 100644 index 0000000..d49f8e2 --- /dev/null +++ b/test/src/test-doneevent.cpp @@ -0,0 +1,63 @@ +#include "uscxml/Interpreter.h" + +using namespace uscxml; + +// -- Issue 56 on github +int main(int argc, char** argv) { + std::deque messageQueue; + messageQueue.push_back("a"); + messageQueue.push_back("b"); + messageQueue.push_back("c"); + messageQueue.push_back("d"); + + const char* scxmlContent = + "" + "" + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + ""; + + std::string msg; + + uscxml::Interpreter scxml = uscxml::Interpreter::fromXML(scxmlContent, ""); + scxml.addMonitor(new StateTransitionMonitor()); + + uscxml::InterpreterState state; + // assume initial stable configuration + do { state = scxml.step(); } while(state > 0); + + while(state != uscxml::USCXML_FINISHED && !messageQueue.empty()) + { + msg = messageQueue.front(); + messageQueue.pop_front(); + + scxml.receive(uscxml::Event(msg, uscxml::Event::EXTERNAL)); + + // step to next stable configuration + do { state = scxml.step(); } while(state > 0); + + } + + return EXIT_SUCCESS; + +} \ No newline at end of file diff --git a/test/src/test-issue-reporting.cpp b/test/src/test-issue-reporting.cpp index e93ba58..7b3d99c 100644 --- a/test/src/test-issue-reporting.cpp +++ b/test/src/test-issue-reporting.cpp @@ -99,7 +99,7 @@ int main(int argc, char** argv) { assert(issueLocations.size() == 1); } - if (1) { + if (0) { // State has no 'id' attribute // *** This is not actually an error! *** const char* xml = diff --git a/test/src/test-lifecycle.cpp b/test/src/test-lifecycle.cpp index ff2fafd..3d675df 100644 --- a/test/src/test-lifecycle.cpp +++ b/test/src/test-lifecycle.cpp @@ -23,6 +23,7 @@ int startedAt; int lastTransitionAt; +bool testIssue56(); #ifdef HAS_EXECINFO_H void printBacktrace(void** array, int size) { @@ -413,4 +414,5 @@ int main(int argc, char** argv) { } } return EXIT_SUCCESS; -} \ No newline at end of file +} + diff --git a/test/w3c/confProlog.xsl b/test/w3c/confProlog.xsl new file mode 100644 index 0000000..f4bf5f2 --- /dev/null +++ b/test/w3c/confProlog.xsl @@ -0,0 +1,770 @@ + + + + + + + + + + + + + + + + + + pass + + + + + + + + + + + + + + fail + + + + + + + + + + + + + prolog + + + + + + var + + + + + + var + + + + + + var + + + + + foo.bar.baz + + + + + + + + + + + + + + + + + + var + + + + + '' + + + + + var + + + + + var + + + + + + + + + + + var.bar + + + + + + return + + + + + + + var(Y) + var(X), Y is X + 1, retractall(var1(_)) + + + + + + + var + var + Var + + + + + + +var +var + Var + + + + + + baz + + + + + #_scxml_foo + + + + + xyz + + + + + foo + + +123 + + + + 27 + + + + + 27 + + + + + 27 + + + + + + _event.name + + + + _event.type + + + + _event.sendid + + + + _event. + + + + + _event.raw + + + + + + _event.data. + + + + + _event.data. + + + + _event.data.Var + + + + + _ioprocessors['http://www.w3.org/TR/scxml/#SCXMLEventProcessor'].location + + + + + + + var + + + + + var + + + + + var + + + + + var + + + + + 's' + + + + + var + + + + + var + + + + + var + + + + + var + + + + + "foo + + + + + + + + + + + + + + X = , var(X) + var + + + + + + + + + + + + + + + var + + + == + + var + + + + + + + + + + + + var + + + === + + + + + + + + + + + + + + var===Var + + + + + + + + + + var==Var + + + + + + + + + +var + +== +'' + + + + + + + + + var + + + = + + var + + + + + + + + var == 123 + + + + + _event.name == '' + + + + + + + + _event.data['Var'] + + + == + + + + + + + + + + + + + + + + +var + +== + + + + + + + + + _event.data == + + + + + _event.data == 123 + + + + typeof _event.data === 'undefined' + + + + + _name === '' + + + + + + + + +(function(str, starts){if (starts === '') return true;if (str == null || starts == null) return false;str = String(str); starts = String(starts);return str.length >= starts.length && str.slice(0, starts.length) === starts;})(var, Var) + + + + + + + In('') + + + + + return + + + + + var + + + + + typeof Var === 'undefined' + + + + + + + + + + !Var + + + + + true + + + + + false + + + + + 'name' in _event && 'type' in _event && 'sendid' in _event && 'origin' in _event && 'invokeid' && 'data' in _event + + + + + in _event.data + + + + + typeof _event. === 'undefined' + + + + + _event.language == 'prolog' + + + + + _event.origintype == '' + + + + + + + + + + + + + + D:\W3C\SCXMLTests\test300.js + + + + D:\foo + + + + + + + _event.origin + _event.origintype + + + + + +[1,2,3] + + + + var(X), member(M, X) + + + + + var + + + + + + 1, 2, 3] + + + + + 7 + + + + var + + + + + 'continue' + + + + var + + + + + + var + [].concat(Var, [4]) + + + + + + [[,],[,]] + + + + + + var + + item + index + + + + + + + + + + var + +[0][0]== && [0][1] == && [1][0] == && [1][1] == + + + + + + + + + + SITE_SPECIFIC_ADDRESS + + + + + + + + + + _ioprocessors['basichttp']['location'] + + + + _ioprocessors['basichttp']['location'] + + + + + _event.raw.search('POST') !== -1 + + + + + + +var + + + + + + + _event.type === 'external' + + + + + +_event.raw.search(/Var=/) !== -1 + + + + + + _event.raw.search('=') !== -1 + + + + _event.raw.search(//) !== -1 + + + + + + _event.raw.match(/=(\S+)$/)[1] + + + + + _event.raw.match(/Var=(\S+)$/)[1] + + + + txt.match(/\n\n(.*)/)[2].split('&')[].split('=')[0] + + + + txt.match(/\n\n(.*)/)[2].split('&')[].split('=')[1] + + + + + '<message source="' + _ioprocessors['basichttp'] + '"' ++ 'xmlns:scxml="http://www.w3.org/2005/07/scxml" version="1.0" xmlns:xsi=:http://www.w3.org/2001/XMLSchema-instance" +xsi:schemaLocation="http://www.w3.org/2005/07/scxml scxml-message.xsd" sourcetype=:scxml"' ++' 'name="name"' + '"' + + '"' + />' + + + + + + 'address=' + _ioprocessors['basichttp'] + "'" + + + + + + _event.raw.match(/\n\naddress=(.*)$/) + + \ No newline at end of file diff --git a/test/w3c/convert-tests.sh b/test/w3c/convert-tests.sh index 5de81d8..e784a44 100755 --- a/test/w3c/convert-tests.sh +++ b/test/w3c/convert-tests.sh @@ -18,24 +18,38 @@ TXMLS=`ls txml/*.txml` # echo "Processing $TXML to $DEST" # java -jar /Users/sradomski/Developer/Applications/SaxonHE9-4-0-7J/saxon9he.jar $TXML confXPath.xsl -o:$DEST # done +# +# for TXML in $TXMLS +# do +# DEST=promela/`basename $TXML .txml`.scxml +# echo "Processing $TXML to $DEST" +# java -jar /Users/sradomski/Developer/Applications/SaxonHE9-4-0-7J/saxon9he.jar $TXML confPromela.xsl -o:$DEST +# done for TXML in $TXMLS do - DEST=promela/`basename $TXML .txml`.scxml + DEST=prolog/`basename $TXML .txml`.scxml echo "Processing $TXML to $DEST" - java -jar /Users/sradomski/Developer/Applications/SaxonHE9-4-0-7J/saxon9he.jar $TXML confPromela.xsl -o:$DEST + java -jar /Users/sradomski/Developer/Applications/SaxonHE9-4-0-7J/saxon9he.jar $TXML confProlog.xsl -o:$DEST done cp txml/*.txt ecma/ cp txml/*.txt xpath/ cp txml/*.txt promela/ +cp txml/*.txt prolog/ find ./ecma -type f -exec grep -Ili 'datamodel="xpath"' {} \; |xargs rm -fv + find ./xpath -type f -exec grep -Ili 'datamodel="ecmascript"' {} \; |xargs rm -fv + find ./promela -type f -exec grep -Ili 'datamodel="xpath"' {} \; |xargs rm -fv find ./promela -type f -exec grep -Ili 'datamodel="ecmascript"' {} \; |xargs rm -fv find ./promela -type f -exec grep -Ili 'datamodel="null"' {} \; |xargs rm -fv +find ./prolog -type f -exec grep -Ili 'datamodel="xpath"' {} \; |xargs rm -fv +find ./prolog -type f -exec grep -Ili 'datamodel="ecmascript"' {} \; |xargs rm -fv +find ./prolog -type f -exec grep -Ili 'datamodel="null"' {} \; |xargs rm -fv + # format all SCXML files SCXMLS=`find . -type f -name '*.scxml'` for SCXML in $SCXMLS diff --git a/test/w3c/prolog/robots.txt b/test/w3c/prolog/robots.txt new file mode 100644 index 0000000..9be2782 --- /dev/null +++ b/test/w3c/prolog/robots.txt @@ -0,0 +1,96 @@ +# +# robots.txt for http://www.w3.org/ +# +# $Id: robots.txt,v 1.67 2014-06-25 13:06:01 ddavis Exp $ +# + +# For use by search.w3.org +User-agent: W3C-gsa +Disallow: /Out-Of-Date + +User-agent: W3T_SE +Disallow: /Out-Of-Date + +User-agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT; MS Search 4.0 Robot) +Disallow: / + +# W3C Link checker +User-agent: W3C-checklink +Disallow: + +# the following settings apply to all bots +User-agent: * +# Blogs - WordPress +# https://codex.wordpress.org/Search_Engine_Optimization_for_WordPress#Robots.txt_Optimization +Disallow: /*/wp-admin/ +Disallow: /*/wp-includes/ +Disallow: /*/wp-content/plugins/ +Disallow: /*/wp-content/cache/ +Disallow: /*/wp-content/themes/ +Disallow: /blog/*/trackback/ +Disallow: /blog/*/feed/ +Disallow: /blog/*/comments/ +Disallow: /blog/*/category/*/* +Disallow: /blog/*/*/trackback/ +Disallow: /blog/*/*/feed/ +Disallow: /blog/*/*/comments/ +Disallow: /blog/*/*? +Disallow: /community/trackback/ +Disallow: /community/feed/ +Disallow: /community/comments/ +Disallow: /community/category/*/* +Disallow: /community/*/trackback/ +Disallow: /community/*/feed/ +Disallow: /community/*/comments/ +Disallow: /community/*/category/*/* +Disallow: /community/*? +Disallow: /Consortium/Offices/trackback/ +Disallow: /Consortium/Offices/feed/ +Disallow: /Consortium/Offices/comments/ +Disallow: /Consortium/Offices/category/*/* +Disallow: /Consortium/Offices/*/trackback/ +Disallow: /Consortium/Offices/*/feed/ +Disallow: /Consortium/Offices/*/comments/ +Disallow: /Consortium/Offices/*? +# Wikis - Mediawiki +# https://www.mediawiki.org/wiki/Manual:Robots.txt +Disallow: /wiki/index.php? +Disallow: /wiki/index.php/Help +Disallow: /wiki/index.php/MediaWiki +Disallow: /wiki/index.php/Special: +Disallow: /wiki/index.php/Template +Disallow: /wiki/skins/ +Disallow: /*/wiki/index.php? +Disallow: /*/wiki/index.php/Help +Disallow: /*/wiki/index.php/MediaWiki +Disallow: /*/wiki/index.php/Special: +Disallow: /*/wiki/index.php/Template +# various other access-controlled or expensive areas +Disallow: /2004/ontaria/basic +Disallow: /Team/ +Disallow: /Project +Disallow: /Web +Disallow: /Systems +Disallow: /History +Disallow: /Out-Of-Date +Disallow: /2002/02/mid +Disallow: /mid/ +Disallow: /2005/06/blog/ +Disallow: /2004/08/W3CTalks +Disallow: /2007/11/Talks/search +Disallow: /People/all/ +Disallow: /RDF/Validator/ARPServlet +Disallow: /2003/03/Translations/byLanguage +Disallow: /2003/03/Translations/byTechnology +Disallow: /2005/11/Translations/Query +Disallow: /2000/06/webdata/xslt +Disallow: /2000/09/webdata/xslt +Disallow: /2005/08/online_xslt/xslt +Disallow: /Bugs/ +Disallow: /Search/Mail/Public/ +Disallow: /2006/02/chartergen +Disallow: /2004/01/pp-impl +Disallow: /Consortium/supporters +Disallow: /2007/08/pyRdfa/ +Disallow: /WAI/PF/comments/ +Disallow: /participate/conferences.xml diff --git a/test/w3c/prolog/test144.scxml b/test/w3c/prolog/test144.scxml new file mode 100644 index 0000000..553c73b --- /dev/null +++ b/test/w3c/prolog/test144.scxml @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test147.scxml b/test/w3c/prolog/test147.scxml new file mode 100644 index 0000000..d900aa3 --- /dev/null +++ b/test/w3c/prolog/test147.scxml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test148.scxml b/test/w3c/prolog/test148.scxml new file mode 100644 index 0000000..fa6fe4b --- /dev/null +++ b/test/w3c/prolog/test148.scxml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test149.scxml b/test/w3c/prolog/test149.scxml new file mode 100644 index 0000000..9a3e107 --- /dev/null +++ b/test/w3c/prolog/test149.scxml @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test150.scxml b/test/w3c/prolog/test150.scxml new file mode 100644 index 0000000..770e672 --- /dev/null +++ b/test/w3c/prolog/test150.scxml @@ -0,0 +1,45 @@ + + + + + + + + [1,2,3] + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test151.scxml b/test/w3c/prolog/test151.scxml new file mode 100644 index 0000000..e3a6ca2 --- /dev/null +++ b/test/w3c/prolog/test151.scxml @@ -0,0 +1,45 @@ + + + + + + + + [1,2,3] + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test152.scxml b/test/w3c/prolog/test152.scxml new file mode 100644 index 0000000..d5473c6 --- /dev/null +++ b/test/w3c/prolog/test152.scxml @@ -0,0 +1,51 @@ + + + + + + + + + + [1,2,3] + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test153.scxml b/test/w3c/prolog/test153.scxml new file mode 100644 index 0000000..daedac0 --- /dev/null +++ b/test/w3c/prolog/test153.scxml @@ -0,0 +1,42 @@ + + + + + + + + + + [1,2,3] + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test155.scxml b/test/w3c/prolog/test155.scxml new file mode 100644 index 0000000..db32543 --- /dev/null +++ b/test/w3c/prolog/test155.scxml @@ -0,0 +1,31 @@ + + + + + + + + [1,2,3] + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test156.scxml b/test/w3c/prolog/test156.scxml new file mode 100644 index 0000000..e94016f --- /dev/null +++ b/test/w3c/prolog/test156.scxml @@ -0,0 +1,33 @@ + + + + + + + + [1,2,3] + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test158.scxml b/test/w3c/prolog/test158.scxml new file mode 100644 index 0000000..91d76ce --- /dev/null +++ b/test/w3c/prolog/test158.scxml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test159.scxml b/test/w3c/prolog/test159.scxml new file mode 100644 index 0000000..28afe9f --- /dev/null +++ b/test/w3c/prolog/test159.scxml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test172.scxml b/test/w3c/prolog/test172.scxml new file mode 100644 index 0000000..1ab596c --- /dev/null +++ b/test/w3c/prolog/test172.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test173.scxml b/test/w3c/prolog/test173.scxml new file mode 100644 index 0000000..e7c85f3 --- /dev/null +++ b/test/w3c/prolog/test173.scxml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test174.scxml b/test/w3c/prolog/test174.scxml new file mode 100644 index 0000000..1b4ae5e --- /dev/null +++ b/test/w3c/prolog/test174.scxml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test175.scxml b/test/w3c/prolog/test175.scxml new file mode 100644 index 0000000..e99f57b --- /dev/null +++ b/test/w3c/prolog/test175.scxml @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test176.scxml b/test/w3c/prolog/test176.scxml new file mode 100644 index 0000000..bf7a339 --- /dev/null +++ b/test/w3c/prolog/test176.scxml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test178.scxml b/test/w3c/prolog/test178.scxml new file mode 100644 index 0000000..6476440 --- /dev/null +++ b/test/w3c/prolog/test178.scxml @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test179.scxml b/test/w3c/prolog/test179.scxml new file mode 100644 index 0000000..d304167 --- /dev/null +++ b/test/w3c/prolog/test179.scxml @@ -0,0 +1,23 @@ + + + + + + + 123 + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test183.scxml b/test/w3c/prolog/test183.scxml new file mode 100644 index 0000000..38e6f73 --- /dev/null +++ b/test/w3c/prolog/test183.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test185.scxml b/test/w3c/prolog/test185.scxml new file mode 100644 index 0000000..8ffe367 --- /dev/null +++ b/test/w3c/prolog/test185.scxml @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test186.scxml b/test/w3c/prolog/test186.scxml new file mode 100644 index 0000000..cf48f54 --- /dev/null +++ b/test/w3c/prolog/test186.scxml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test187.scxml b/test/w3c/prolog/test187.scxml new file mode 100644 index 0000000..b59d404 --- /dev/null +++ b/test/w3c/prolog/test187.scxml @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test189.scxml b/test/w3c/prolog/test189.scxml new file mode 100644 index 0000000..713cb6a --- /dev/null +++ b/test/w3c/prolog/test189.scxml @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test190.scxml b/test/w3c/prolog/test190.scxml new file mode 100644 index 0000000..be5fd5e --- /dev/null +++ b/test/w3c/prolog/test190.scxml @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test191.scxml b/test/w3c/prolog/test191.scxml new file mode 100644 index 0000000..11d03c0 --- /dev/null +++ b/test/w3c/prolog/test191.scxml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test192.scxml b/test/w3c/prolog/test192.scxml new file mode 100644 index 0000000..7c461e4 --- /dev/null +++ b/test/w3c/prolog/test192.scxml @@ -0,0 +1,52 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test193.scxml b/test/w3c/prolog/test193.scxml new file mode 100644 index 0000000..574ba84 --- /dev/null +++ b/test/w3c/prolog/test193.scxml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test194.scxml b/test/w3c/prolog/test194.scxml new file mode 100644 index 0000000..cfdc689 --- /dev/null +++ b/test/w3c/prolog/test194.scxml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test198.scxml b/test/w3c/prolog/test198.scxml new file mode 100644 index 0000000..026fcad --- /dev/null +++ b/test/w3c/prolog/test198.scxml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test199.scxml b/test/w3c/prolog/test199.scxml new file mode 100644 index 0000000..c1e6c33 --- /dev/null +++ b/test/w3c/prolog/test199.scxml @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test200.scxml b/test/w3c/prolog/test200.scxml new file mode 100644 index 0000000..a861a02 --- /dev/null +++ b/test/w3c/prolog/test200.scxml @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test201.scxml b/test/w3c/prolog/test201.scxml new file mode 100644 index 0000000..b04be33 --- /dev/null +++ b/test/w3c/prolog/test201.scxml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test205.scxml b/test/w3c/prolog/test205.scxml new file mode 100644 index 0000000..364a8d5 --- /dev/null +++ b/test/w3c/prolog/test205.scxml @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test207.scxml b/test/w3c/prolog/test207.scxml new file mode 100644 index 0000000..860a307 --- /dev/null +++ b/test/w3c/prolog/test207.scxml @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test208.scxml b/test/w3c/prolog/test208.scxml new file mode 100644 index 0000000..6211869 --- /dev/null +++ b/test/w3c/prolog/test208.scxml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test210.scxml b/test/w3c/prolog/test210.scxml new file mode 100644 index 0000000..efcde02 --- /dev/null +++ b/test/w3c/prolog/test210.scxml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test215.scxml b/test/w3c/prolog/test215.scxml new file mode 100644 index 0000000..948fd96 --- /dev/null +++ b/test/w3c/prolog/test215.scxml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test216.scxml b/test/w3c/prolog/test216.scxml new file mode 100644 index 0000000..6b45034 --- /dev/null +++ b/test/w3c/prolog/test216.scxml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test216sub1.scxml b/test/w3c/prolog/test216sub1.scxml new file mode 100644 index 0000000..53ff2d6 --- /dev/null +++ b/test/w3c/prolog/test216sub1.scxml @@ -0,0 +1,5 @@ + + + + + diff --git a/test/w3c/prolog/test220.scxml b/test/w3c/prolog/test220.scxml new file mode 100644 index 0000000..d0cde37 --- /dev/null +++ b/test/w3c/prolog/test220.scxml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test223.scxml b/test/w3c/prolog/test223.scxml new file mode 100644 index 0000000..c92fab9 --- /dev/null +++ b/test/w3c/prolog/test223.scxml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test224.scxml b/test/w3c/prolog/test224.scxml new file mode 100644 index 0000000..11753f7 --- /dev/null +++ b/test/w3c/prolog/test224.scxml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test225.scxml b/test/w3c/prolog/test225.scxml new file mode 100644 index 0000000..2d6e550 --- /dev/null +++ b/test/w3c/prolog/test225.scxml @@ -0,0 +1,42 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test226.scxml b/test/w3c/prolog/test226.scxml new file mode 100644 index 0000000..5635c19 --- /dev/null +++ b/test/w3c/prolog/test226.scxml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test226sub1.scxml b/test/w3c/prolog/test226sub1.scxml new file mode 100644 index 0000000..c2e856c --- /dev/null +++ b/test/w3c/prolog/test226sub1.scxml @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test228.scxml b/test/w3c/prolog/test228.scxml new file mode 100644 index 0000000..a695cfb --- /dev/null +++ b/test/w3c/prolog/test228.scxml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test229.scxml b/test/w3c/prolog/test229.scxml new file mode 100644 index 0000000..4ecc238 --- /dev/null +++ b/test/w3c/prolog/test229.scxml @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test230.scxml b/test/w3c/prolog/test230.scxml new file mode 100644 index 0000000..066362b --- /dev/null +++ b/test/w3c/prolog/test230.scxml @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test232.scxml b/test/w3c/prolog/test232.scxml new file mode 100644 index 0000000..f3d3186 --- /dev/null +++ b/test/w3c/prolog/test232.scxml @@ -0,0 +1,41 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test233.scxml b/test/w3c/prolog/test233.scxml new file mode 100644 index 0000000..d67aa2d --- /dev/null +++ b/test/w3c/prolog/test233.scxml @@ -0,0 +1,42 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test234.scxml b/test/w3c/prolog/test234.scxml new file mode 100644 index 0000000..6f11dab --- /dev/null +++ b/test/w3c/prolog/test234.scxml @@ -0,0 +1,69 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test235.scxml b/test/w3c/prolog/test235.scxml new file mode 100644 index 0000000..acc4b61 --- /dev/null +++ b/test/w3c/prolog/test235.scxml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test236.scxml b/test/w3c/prolog/test236.scxml new file mode 100644 index 0000000..9cc1a27 --- /dev/null +++ b/test/w3c/prolog/test236.scxml @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test237.scxml b/test/w3c/prolog/test237.scxml new file mode 100644 index 0000000..a3ec4c5 --- /dev/null +++ b/test/w3c/prolog/test237.scxml @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test239.scxml b/test/w3c/prolog/test239.scxml new file mode 100644 index 0000000..05a4b05 --- /dev/null +++ b/test/w3c/prolog/test239.scxml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test239sub1.scxml b/test/w3c/prolog/test239sub1.scxml new file mode 100644 index 0000000..7ca8049 --- /dev/null +++ b/test/w3c/prolog/test239sub1.scxml @@ -0,0 +1,5 @@ + + + + + diff --git a/test/w3c/prolog/test240.scxml b/test/w3c/prolog/test240.scxml new file mode 100644 index 0000000..8fa7804 --- /dev/null +++ b/test/w3c/prolog/test240.scxml @@ -0,0 +1,71 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test241.scxml b/test/w3c/prolog/test241.scxml new file mode 100644 index 0000000..287f6f7 --- /dev/null +++ b/test/w3c/prolog/test241.scxml @@ -0,0 +1,96 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test242.scxml b/test/w3c/prolog/test242.scxml new file mode 100644 index 0000000..df5e563 --- /dev/null +++ b/test/w3c/prolog/test242.scxml @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test242sub1.scxml b/test/w3c/prolog/test242sub1.scxml new file mode 100644 index 0000000..7ca8049 --- /dev/null +++ b/test/w3c/prolog/test242sub1.scxml @@ -0,0 +1,5 @@ + + + + + diff --git a/test/w3c/prolog/test243.scxml b/test/w3c/prolog/test243.scxml new file mode 100644 index 0000000..76b66e0 --- /dev/null +++ b/test/w3c/prolog/test243.scxml @@ -0,0 +1,41 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test244.scxml b/test/w3c/prolog/test244.scxml new file mode 100644 index 0000000..7e1e29d --- /dev/null +++ b/test/w3c/prolog/test244.scxml @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test245.scxml b/test/w3c/prolog/test245.scxml new file mode 100644 index 0000000..3ff9866 --- /dev/null +++ b/test/w3c/prolog/test245.scxml @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test247.scxml b/test/w3c/prolog/test247.scxml new file mode 100644 index 0000000..7db10ac --- /dev/null +++ b/test/w3c/prolog/test247.scxml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test250.scxml b/test/w3c/prolog/test250.scxml new file mode 100644 index 0000000..6eeb1a6 --- /dev/null +++ b/test/w3c/prolog/test250.scxml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test252.scxml b/test/w3c/prolog/test252.scxml new file mode 100644 index 0000000..c940c33 --- /dev/null +++ b/test/w3c/prolog/test252.scxml @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test253.scxml b/test/w3c/prolog/test253.scxml new file mode 100644 index 0000000..41734af --- /dev/null +++ b/test/w3c/prolog/test253.scxml @@ -0,0 +1,75 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test276.scxml b/test/w3c/prolog/test276.scxml new file mode 100644 index 0000000..9e1a219 --- /dev/null +++ b/test/w3c/prolog/test276.scxml @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test276sub1.scxml b/test/w3c/prolog/test276sub1.scxml new file mode 100644 index 0000000..3b25942 --- /dev/null +++ b/test/w3c/prolog/test276sub1.scxml @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test277.scxml b/test/w3c/prolog/test277.scxml new file mode 100644 index 0000000..54a748a --- /dev/null +++ b/test/w3c/prolog/test277.scxml @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test278.scxml b/test/w3c/prolog/test278.scxml new file mode 100644 index 0000000..11cae5b --- /dev/null +++ b/test/w3c/prolog/test278.scxml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test279.scxml b/test/w3c/prolog/test279.scxml new file mode 100644 index 0000000..1c4624e --- /dev/null +++ b/test/w3c/prolog/test279.scxml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test280.scxml b/test/w3c/prolog/test280.scxml new file mode 100644 index 0000000..2384f98 --- /dev/null +++ b/test/w3c/prolog/test280.scxml @@ -0,0 +1,33 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test286.scxml b/test/w3c/prolog/test286.scxml new file mode 100644 index 0000000..6d261fb --- /dev/null +++ b/test/w3c/prolog/test286.scxml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test287.scxml b/test/w3c/prolog/test287.scxml new file mode 100644 index 0000000..21087c9 --- /dev/null +++ b/test/w3c/prolog/test287.scxml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test288.scxml b/test/w3c/prolog/test288.scxml new file mode 100644 index 0000000..76ae21b --- /dev/null +++ b/test/w3c/prolog/test288.scxml @@ -0,0 +1,25 @@ + + + + + + + + + 123 + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test294.scxml b/test/w3c/prolog/test294.scxml new file mode 100644 index 0000000..909db1a --- /dev/null +++ b/test/w3c/prolog/test294.scxml @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + foo + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test298.scxml b/test/w3c/prolog/test298.scxml new file mode 100644 index 0000000..cdc2c40 --- /dev/null +++ b/test/w3c/prolog/test298.scxml @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test301.scxml b/test/w3c/prolog/test301.scxml new file mode 100644 index 0000000..0b2bd50 --- /dev/null +++ b/test/w3c/prolog/test301.scxml @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test303.scxml b/test/w3c/prolog/test303.scxml new file mode 100644 index 0000000..2486845 --- /dev/null +++ b/test/w3c/prolog/test303.scxml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test304.scxml b/test/w3c/prolog/test304.scxml new file mode 100644 index 0000000..15ef800 --- /dev/null +++ b/test/w3c/prolog/test304.scxml @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test307.scxml b/test/w3c/prolog/test307.scxml new file mode 100644 index 0000000..bcd0233 --- /dev/null +++ b/test/w3c/prolog/test307.scxml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test309.scxml b/test/w3c/prolog/test309.scxml new file mode 100644 index 0000000..8b8d098 --- /dev/null +++ b/test/w3c/prolog/test309.scxml @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test310.scxml b/test/w3c/prolog/test310.scxml new file mode 100644 index 0000000..cee088b --- /dev/null +++ b/test/w3c/prolog/test310.scxml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test311.scxml b/test/w3c/prolog/test311.scxml new file mode 100644 index 0000000..03fd93b --- /dev/null +++ b/test/w3c/prolog/test311.scxml @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test312.scxml b/test/w3c/prolog/test312.scxml new file mode 100644 index 0000000..8af1252 --- /dev/null +++ b/test/w3c/prolog/test312.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test313.scxml b/test/w3c/prolog/test313.scxml new file mode 100644 index 0000000..1a6b25c --- /dev/null +++ b/test/w3c/prolog/test313.scxml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test314.scxml b/test/w3c/prolog/test314.scxml new file mode 100644 index 0000000..486199a --- /dev/null +++ b/test/w3c/prolog/test314.scxml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test318.scxml b/test/w3c/prolog/test318.scxml new file mode 100644 index 0000000..4b1cc5c --- /dev/null +++ b/test/w3c/prolog/test318.scxml @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test319.scxml b/test/w3c/prolog/test319.scxml new file mode 100644 index 0000000..f6649d9 --- /dev/null +++ b/test/w3c/prolog/test319.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test321.scxml b/test/w3c/prolog/test321.scxml new file mode 100644 index 0000000..6b36518 --- /dev/null +++ b/test/w3c/prolog/test321.scxml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test322.scxml b/test/w3c/prolog/test322.scxml new file mode 100644 index 0000000..cbb2970 --- /dev/null +++ b/test/w3c/prolog/test322.scxml @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test323.scxml b/test/w3c/prolog/test323.scxml new file mode 100644 index 0000000..3976bec --- /dev/null +++ b/test/w3c/prolog/test323.scxml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test324.scxml b/test/w3c/prolog/test324.scxml new file mode 100644 index 0000000..67231ef --- /dev/null +++ b/test/w3c/prolog/test324.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test325.scxml b/test/w3c/prolog/test325.scxml new file mode 100644 index 0000000..9be15e3 --- /dev/null +++ b/test/w3c/prolog/test325.scxml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test326.scxml b/test/w3c/prolog/test326.scxml new file mode 100644 index 0000000..2938eff --- /dev/null +++ b/test/w3c/prolog/test326.scxml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test329.scxml b/test/w3c/prolog/test329.scxml new file mode 100644 index 0000000..5e8f502 --- /dev/null +++ b/test/w3c/prolog/test329.scxml @@ -0,0 +1,54 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test330.scxml b/test/w3c/prolog/test330.scxml new file mode 100644 index 0000000..0d6c81e --- /dev/null +++ b/test/w3c/prolog/test330.scxml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test331.scxml b/test/w3c/prolog/test331.scxml new file mode 100644 index 0000000..3686d7d --- /dev/null +++ b/test/w3c/prolog/test331.scxml @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test332.scxml b/test/w3c/prolog/test332.scxml new file mode 100644 index 0000000..c353cb9 --- /dev/null +++ b/test/w3c/prolog/test332.scxml @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test333.scxml b/test/w3c/prolog/test333.scxml new file mode 100644 index 0000000..3d74685 --- /dev/null +++ b/test/w3c/prolog/test333.scxml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test335.scxml b/test/w3c/prolog/test335.scxml new file mode 100644 index 0000000..9abb44d --- /dev/null +++ b/test/w3c/prolog/test335.scxml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test336.scxml b/test/w3c/prolog/test336.scxml new file mode 100644 index 0000000..ad825bd --- /dev/null +++ b/test/w3c/prolog/test336.scxml @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test337.scxml b/test/w3c/prolog/test337.scxml new file mode 100644 index 0000000..ee119e4 --- /dev/null +++ b/test/w3c/prolog/test337.scxml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test338.scxml b/test/w3c/prolog/test338.scxml new file mode 100644 index 0000000..3114c72 --- /dev/null +++ b/test/w3c/prolog/test338.scxml @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test339.scxml b/test/w3c/prolog/test339.scxml new file mode 100644 index 0000000..549290c --- /dev/null +++ b/test/w3c/prolog/test339.scxml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test342.scxml b/test/w3c/prolog/test342.scxml new file mode 100644 index 0000000..4d1e7ff --- /dev/null +++ b/test/w3c/prolog/test342.scxml @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test343.scxml b/test/w3c/prolog/test343.scxml new file mode 100644 index 0000000..ca0e0db --- /dev/null +++ b/test/w3c/prolog/test343.scxml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test344.scxml b/test/w3c/prolog/test344.scxml new file mode 100644 index 0000000..80a5b31 --- /dev/null +++ b/test/w3c/prolog/test344.scxml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test346.scxml b/test/w3c/prolog/test346.scxml new file mode 100644 index 0000000..8db600c --- /dev/null +++ b/test/w3c/prolog/test346.scxml @@ -0,0 +1,54 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test347.scxml b/test/w3c/prolog/test347.scxml new file mode 100644 index 0000000..2f6c513 --- /dev/null +++ b/test/w3c/prolog/test347.scxml @@ -0,0 +1,44 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test348.scxml b/test/w3c/prolog/test348.scxml new file mode 100644 index 0000000..7f9692a --- /dev/null +++ b/test/w3c/prolog/test348.scxml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test349.scxml b/test/w3c/prolog/test349.scxml new file mode 100644 index 0000000..88a01d3 --- /dev/null +++ b/test/w3c/prolog/test349.scxml @@ -0,0 +1,33 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test350.scxml b/test/w3c/prolog/test350.scxml new file mode 100644 index 0000000..b94aac0 --- /dev/null +++ b/test/w3c/prolog/test350.scxml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test351.scxml b/test/w3c/prolog/test351.scxml new file mode 100644 index 0000000..9ff43ba --- /dev/null +++ b/test/w3c/prolog/test351.scxml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test352.scxml b/test/w3c/prolog/test352.scxml new file mode 100644 index 0000000..47f76c5 --- /dev/null +++ b/test/w3c/prolog/test352.scxml @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test354.scxml b/test/w3c/prolog/test354.scxml new file mode 100644 index 0000000..aa30cbf --- /dev/null +++ b/test/w3c/prolog/test354.scxml @@ -0,0 +1,52 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 123 + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test355.scxml b/test/w3c/prolog/test355.scxml new file mode 100644 index 0000000..effca22 --- /dev/null +++ b/test/w3c/prolog/test355.scxml @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test364.scxml b/test/w3c/prolog/test364.scxml new file mode 100644 index 0000000..b98eebc --- /dev/null +++ b/test/w3c/prolog/test364.scxml @@ -0,0 +1,79 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test372.scxml b/test/w3c/prolog/test372.scxml new file mode 100644 index 0000000..cd6cac2 --- /dev/null +++ b/test/w3c/prolog/test372.scxml @@ -0,0 +1,33 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test375.scxml b/test/w3c/prolog/test375.scxml new file mode 100644 index 0000000..21db985 --- /dev/null +++ b/test/w3c/prolog/test375.scxml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test376.scxml b/test/w3c/prolog/test376.scxml new file mode 100644 index 0000000..9722c3c --- /dev/null +++ b/test/w3c/prolog/test376.scxml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test377.scxml b/test/w3c/prolog/test377.scxml new file mode 100644 index 0000000..503147e --- /dev/null +++ b/test/w3c/prolog/test377.scxml @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test378.scxml b/test/w3c/prolog/test378.scxml new file mode 100644 index 0000000..b8fdc59 --- /dev/null +++ b/test/w3c/prolog/test378.scxml @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test387.scxml b/test/w3c/prolog/test387.scxml new file mode 100644 index 0000000..96c6646 --- /dev/null +++ b/test/w3c/prolog/test387.scxml @@ -0,0 +1,93 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test388.scxml b/test/w3c/prolog/test388.scxml new file mode 100644 index 0000000..537ccd6 --- /dev/null +++ b/test/w3c/prolog/test388.scxml @@ -0,0 +1,74 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test396.scxml b/test/w3c/prolog/test396.scxml new file mode 100644 index 0000000..2bf5f17 --- /dev/null +++ b/test/w3c/prolog/test396.scxml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test399.scxml b/test/w3c/prolog/test399.scxml new file mode 100644 index 0000000..3401a23 --- /dev/null +++ b/test/w3c/prolog/test399.scxml @@ -0,0 +1,65 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test401.scxml b/test/w3c/prolog/test401.scxml new file mode 100644 index 0000000..69628da --- /dev/null +++ b/test/w3c/prolog/test401.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test402.scxml b/test/w3c/prolog/test402.scxml new file mode 100644 index 0000000..26dac89 --- /dev/null +++ b/test/w3c/prolog/test402.scxml @@ -0,0 +1,42 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test403a.scxml b/test/w3c/prolog/test403a.scxml new file mode 100644 index 0000000..67bb1e3 --- /dev/null +++ b/test/w3c/prolog/test403a.scxml @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test403b.scxml b/test/w3c/prolog/test403b.scxml new file mode 100644 index 0000000..daa7c91 --- /dev/null +++ b/test/w3c/prolog/test403b.scxml @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test403c.scxml b/test/w3c/prolog/test403c.scxml new file mode 100644 index 0000000..cf16c68 --- /dev/null +++ b/test/w3c/prolog/test403c.scxml @@ -0,0 +1,53 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test404.scxml b/test/w3c/prolog/test404.scxml new file mode 100644 index 0000000..d8c7ac8 --- /dev/null +++ b/test/w3c/prolog/test404.scxml @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test405.scxml b/test/w3c/prolog/test405.scxml new file mode 100644 index 0000000..0f817fa --- /dev/null +++ b/test/w3c/prolog/test405.scxml @@ -0,0 +1,66 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test406.scxml b/test/w3c/prolog/test406.scxml new file mode 100644 index 0000000..528918a --- /dev/null +++ b/test/w3c/prolog/test406.scxml @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test407.scxml b/test/w3c/prolog/test407.scxml new file mode 100644 index 0000000..f7c4d6a --- /dev/null +++ b/test/w3c/prolog/test407.scxml @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test409.scxml b/test/w3c/prolog/test409.scxml new file mode 100644 index 0000000..1719da1 --- /dev/null +++ b/test/w3c/prolog/test409.scxml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test411.scxml b/test/w3c/prolog/test411.scxml new file mode 100644 index 0000000..6ac8523 --- /dev/null +++ b/test/w3c/prolog/test411.scxml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test412.scxml b/test/w3c/prolog/test412.scxml new file mode 100644 index 0000000..fad7a3e --- /dev/null +++ b/test/w3c/prolog/test412.scxml @@ -0,0 +1,52 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test413.scxml b/test/w3c/prolog/test413.scxml new file mode 100644 index 0000000..a9afc67 --- /dev/null +++ b/test/w3c/prolog/test413.scxml @@ -0,0 +1,44 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test415.scxml b/test/w3c/prolog/test415.scxml new file mode 100644 index 0000000..c2859c1 --- /dev/null +++ b/test/w3c/prolog/test415.scxml @@ -0,0 +1,13 @@ + + + + + + + + + diff --git a/test/w3c/prolog/test416.scxml b/test/w3c/prolog/test416.scxml new file mode 100644 index 0000000..54a3d83 --- /dev/null +++ b/test/w3c/prolog/test416.scxml @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test417.scxml b/test/w3c/prolog/test417.scxml new file mode 100644 index 0000000..8c9cb96 --- /dev/null +++ b/test/w3c/prolog/test417.scxml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test419.scxml b/test/w3c/prolog/test419.scxml new file mode 100644 index 0000000..6f159f7 --- /dev/null +++ b/test/w3c/prolog/test419.scxml @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test421.scxml b/test/w3c/prolog/test421.scxml new file mode 100644 index 0000000..8a83601 --- /dev/null +++ b/test/w3c/prolog/test421.scxml @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test422.scxml b/test/w3c/prolog/test422.scxml new file mode 100644 index 0000000..4480698 --- /dev/null +++ b/test/w3c/prolog/test422.scxml @@ -0,0 +1,81 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test423.scxml b/test/w3c/prolog/test423.scxml new file mode 100644 index 0000000..1a110d6 --- /dev/null +++ b/test/w3c/prolog/test423.scxml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test446.txt b/test/w3c/prolog/test446.txt new file mode 100644 index 0000000..3a26a2e --- /dev/null +++ b/test/w3c/prolog/test446.txt @@ -0,0 +1 @@ +[1,2,3] \ No newline at end of file diff --git a/test/w3c/prolog/test487.scxml b/test/w3c/prolog/test487.scxml new file mode 100644 index 0000000..b9d1f60 --- /dev/null +++ b/test/w3c/prolog/test487.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test488.scxml b/test/w3c/prolog/test488.scxml new file mode 100644 index 0000000..22e7714 --- /dev/null +++ b/test/w3c/prolog/test488.scxml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test495.scxml b/test/w3c/prolog/test495.scxml new file mode 100644 index 0000000..230f747 --- /dev/null +++ b/test/w3c/prolog/test495.scxml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test496.scxml b/test/w3c/prolog/test496.scxml new file mode 100644 index 0000000..52acced --- /dev/null +++ b/test/w3c/prolog/test496.scxml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test500.scxml b/test/w3c/prolog/test500.scxml new file mode 100644 index 0000000..16f5209 --- /dev/null +++ b/test/w3c/prolog/test500.scxml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test501.scxml b/test/w3c/prolog/test501.scxml new file mode 100644 index 0000000..28b8ffe --- /dev/null +++ b/test/w3c/prolog/test501.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test503.scxml b/test/w3c/prolog/test503.scxml new file mode 100644 index 0000000..67d463f --- /dev/null +++ b/test/w3c/prolog/test503.scxml @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test504.scxml b/test/w3c/prolog/test504.scxml new file mode 100644 index 0000000..9ef3704 --- /dev/null +++ b/test/w3c/prolog/test504.scxml @@ -0,0 +1,79 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test505.scxml b/test/w3c/prolog/test505.scxml new file mode 100644 index 0000000..bfcb9fb --- /dev/null +++ b/test/w3c/prolog/test505.scxml @@ -0,0 +1,52 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test506.scxml b/test/w3c/prolog/test506.scxml new file mode 100644 index 0000000..2cd176f --- /dev/null +++ b/test/w3c/prolog/test506.scxml @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test509.scxml b/test/w3c/prolog/test509.scxml new file mode 100644 index 0000000..d5ac65a --- /dev/null +++ b/test/w3c/prolog/test509.scxml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test510.scxml b/test/w3c/prolog/test510.scxml new file mode 100644 index 0000000..07a91e9 --- /dev/null +++ b/test/w3c/prolog/test510.scxml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test513.txt b/test/w3c/prolog/test513.txt new file mode 100644 index 0000000..08e9b01 --- /dev/null +++ b/test/w3c/prolog/test513.txt @@ -0,0 +1,16 @@ +This is a fully manual test. You send a well formed event to the 'location' URL + specified for your SCXML interpreter and check that you get a 200 response code back. + One way of doing this, using wget, is shown below (you can use any event name you + want, but you must use '_scxmleventname' to indicate the name of the event): + +$ wget \ +--post-data='key1=value1&key2=value2' \ +--header '_scxmleventname: test' \ + + +--2014-06-25 17:54:49-- http://epikur.local:8090/925c760f-2093-4054-a24c-d972d75f0dcd/basichttp +Resolving epikur.local (epikur.local)... 10.211.55.2, 10.37.129.2, 10.0.1.54, ... +Connecting to epikur.local (epikur.local)|10.211.55.2|:8090... connected. +HTTP request sent, awaiting response... 200 OK +Length: 0 [text/html] +Saving to: ‘basichttp’ \ No newline at end of file diff --git a/test/w3c/prolog/test518.scxml b/test/w3c/prolog/test518.scxml new file mode 100644 index 0000000..94cb6e7 --- /dev/null +++ b/test/w3c/prolog/test518.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test519.scxml b/test/w3c/prolog/test519.scxml new file mode 100644 index 0000000..11053b5 --- /dev/null +++ b/test/w3c/prolog/test519.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test520.scxml b/test/w3c/prolog/test520.scxml new file mode 100644 index 0000000..f0fff26 --- /dev/null +++ b/test/w3c/prolog/test520.scxml @@ -0,0 +1,27 @@ + + + + + + + + this is some content + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test521.scxml b/test/w3c/prolog/test521.scxml new file mode 100644 index 0000000..3cf09ce --- /dev/null +++ b/test/w3c/prolog/test521.scxml @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test522.scxml b/test/w3c/prolog/test522.scxml new file mode 100644 index 0000000..8a24fe7 --- /dev/null +++ b/test/w3c/prolog/test522.scxml @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test525.scxml b/test/w3c/prolog/test525.scxml new file mode 100644 index 0000000..a2a63e8 --- /dev/null +++ b/test/w3c/prolog/test525.scxml @@ -0,0 +1,32 @@ + + + + + + [1,2,3] + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test527.scxml b/test/w3c/prolog/test527.scxml new file mode 100644 index 0000000..5b894fb --- /dev/null +++ b/test/w3c/prolog/test527.scxml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test528.scxml b/test/w3c/prolog/test528.scxml new file mode 100644 index 0000000..eaed3bf --- /dev/null +++ b/test/w3c/prolog/test528.scxml @@ -0,0 +1,33 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test529.scxml b/test/w3c/prolog/test529.scxml new file mode 100644 index 0000000..6c3285e --- /dev/null +++ b/test/w3c/prolog/test529.scxml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + 21 + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test530.scxml b/test/w3c/prolog/test530.scxml new file mode 100644 index 0000000..ab90271 --- /dev/null +++ b/test/w3c/prolog/test530.scxml @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test531.scxml b/test/w3c/prolog/test531.scxml new file mode 100644 index 0000000..f3d114f --- /dev/null +++ b/test/w3c/prolog/test531.scxml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test532.scxml b/test/w3c/prolog/test532.scxml new file mode 100644 index 0000000..498fc9f --- /dev/null +++ b/test/w3c/prolog/test532.scxml @@ -0,0 +1,26 @@ + + + + + + + + + some content + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test533.scxml b/test/w3c/prolog/test533.scxml new file mode 100644 index 0000000..5f8d4f0 --- /dev/null +++ b/test/w3c/prolog/test533.scxml @@ -0,0 +1,67 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test534.scxml b/test/w3c/prolog/test534.scxml new file mode 100644 index 0000000..89fa296 --- /dev/null +++ b/test/w3c/prolog/test534.scxml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test539.txt b/test/w3c/prolog/test539.txt new file mode 100644 index 0000000..de1b0a1 --- /dev/null +++ b/test/w3c/prolog/test539.txt @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/test/w3c/prolog/test540.txt b/test/w3c/prolog/test540.txt new file mode 100644 index 0000000..2191239 --- /dev/null +++ b/test/w3c/prolog/test540.txt @@ -0,0 +1,3 @@ +123 +4 5 + \ No newline at end of file diff --git a/test/w3c/prolog/test550.scxml b/test/w3c/prolog/test550.scxml new file mode 100644 index 0000000..9094853 --- /dev/null +++ b/test/w3c/prolog/test550.scxml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test551.scxml b/test/w3c/prolog/test551.scxml new file mode 100644 index 0000000..733ee3d --- /dev/null +++ b/test/w3c/prolog/test551.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + [1,2,3] + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test552.scxml b/test/w3c/prolog/test552.scxml new file mode 100644 index 0000000..527d6b6 --- /dev/null +++ b/test/w3c/prolog/test552.scxml @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test552.txt b/test/w3c/prolog/test552.txt new file mode 100644 index 0000000..d8263ee --- /dev/null +++ b/test/w3c/prolog/test552.txt @@ -0,0 +1 @@ +2 \ No newline at end of file diff --git a/test/w3c/prolog/test553.scxml b/test/w3c/prolog/test553.scxml new file mode 100644 index 0000000..8ab2b2c --- /dev/null +++ b/test/w3c/prolog/test553.scxml @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test554.scxml b/test/w3c/prolog/test554.scxml new file mode 100644 index 0000000..5c89cf1 --- /dev/null +++ b/test/w3c/prolog/test554.scxml @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test557.txt b/test/w3c/prolog/test557.txt new file mode 100644 index 0000000..a8e51da --- /dev/null +++ b/test/w3c/prolog/test557.txt @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/test/w3c/prolog/test558.txt b/test/w3c/prolog/test558.txt new file mode 100644 index 0000000..bb2bcc7 --- /dev/null +++ b/test/w3c/prolog/test558.txt @@ -0,0 +1,3 @@ + +this is +a string \ No newline at end of file diff --git a/test/w3c/prolog/test567.scxml b/test/w3c/prolog/test567.scxml new file mode 100644 index 0000000..cfb8f5a --- /dev/null +++ b/test/w3c/prolog/test567.scxml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test570.scxml b/test/w3c/prolog/test570.scxml new file mode 100644 index 0000000..8e0dc38 --- /dev/null +++ b/test/w3c/prolog/test570.scxml @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test576.scxml b/test/w3c/prolog/test576.scxml new file mode 100644 index 0000000..97ea544 --- /dev/null +++ b/test/w3c/prolog/test576.scxml @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test577.scxml b/test/w3c/prolog/test577.scxml new file mode 100644 index 0000000..f412a33 --- /dev/null +++ b/test/w3c/prolog/test577.scxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test579.scxml b/test/w3c/prolog/test579.scxml new file mode 100644 index 0000000..851b103 --- /dev/null +++ b/test/w3c/prolog/test579.scxml @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/prolog/test580.scxml b/test/w3c/prolog/test580.scxml new file mode 100644 index 0000000..6034e42 --- /dev/null +++ b/test/w3c/prolog/test580.scxml @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/w3c/promela/test150.scxml b/test/w3c/promela/test150.scxml index 6e97c46..3816c3e 100644 --- a/test/w3c/promela/test150.scxml +++ b/test/w3c/promela/test150.scxml @@ -1,41 +1,45 @@ - - - - - + + + + + + + [1,2,3] - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- cgit v0.12