forked from sdiawara/cudl
-
Notifications
You must be signed in to change notification settings - Fork 0
Home
lmazardo edited this page Mar 23, 2012
·
16 revisions
Cudl is a VoiceXML testing tool.
- Download the jar Here.
- Put it in your java project and you juste follow the example bellow.
This is a sample "hello word" in VoiceXML.
<?xml version="1.0" encoding="UTF-8"?>
<vxml xmlns="http://www.w3.org/2001/vxml"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.w3.org/2001/vxml
http://www.w3.org/TR/voicexml20/vxml.xsd"
version="2.0">
<form>
<block>Hello Word !</block>
</form>
</vxml>
The code bellow test the prompt "Hello word !" is heart when the above the file is exécuted.
public void testDireBonjour() throws IOException, SAXException, ParserConfigurationException {
List<Prompt> exceptedPrompts = new ArrayList<Prompt>();
Prompt prompt = new Prompt();
prompt.tts = "Hello word !";
exceptedPrompts.add(prompt);
interpreter = new Interpreter("file:hello.vxml");
interpreter.start();
assertEquals(exceptedPrompts, interpreter.getPrompts());
}