web stats
Testing Mirth Channels - Mirth Community

Go Back   Mirth Community > Mirth Connect > General Discussion

Reply
 
Thread Tools Display Modes
  #1  
Old 06-08-2007, 09:34 AM
cord73 cord73 is offline
Mirth Newb
 
Join Date: Apr 2007
Posts: 20
cord73
Default Testing Mirth Channels

I was wondering if anyone has automated testing individual mirth channels or done anything to unit test the javascript, perhaps there are some tools out there that I don't know about. I've looked around the forums but I can't say I've seen a whole lot. If anyone has some first-hand experience with this or some ideas, I'd appreciate the help.

Thanks
Reply With Quote
  #2  
Old 06-13-2007, 09:57 AM
asmith asmith is offline
Mirth Newb
 
Join Date: Jan 2007
Posts: 9
asmith is an unknown quantity at this point
Default Re:Testing Mirth Channels

The term unit testing can mean different things to different people in different situations. For the purpose of this response, I will define it as the testing of a single channel.

There are three (3) components to unit testing: input; output; and verification.

For the input, I create a Unit Test Channel that is a FileReader (to read the test messages) and some sort of an output. The output must match the input of the channel you are testing. In my case, it is a LLP Sender as the channel being tested is a LLP Listener. To send the messages to the channel being tested, you just drop the files in the directory being monitored by the FileReader.

For the output, the channel being tested must output in a format that is compatible for verification (the next step). To do this you could, for example, add a Destination that writes a file that can be verified. Alternatively, you could create another channel responsible for capturing the output of the channel being tested, and write it to a file.

For verification, the easiest thing to do (so far for me) is to compare the output file to either the input file or some other control file (useful if the processing modifies the input message). You could do this with a shell script and the MD5SUM command (for example).

In my opinion, the key is to leverage Mirth for the Input and Output steps, and then use your operating system to verify, and automate the process.

If you want to do Integration Testing, you can then chain your channels together.

This doesn't help if you want to test on a smaller scale (that is, just test the Javascript).

I hope this helps.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Testing and inserting for a segment hjohnson Support 6 11-25-2008 05:49 AM
Synchronous channels in Mirth rbloom Support 1 07-28-2008 05:30 AM
HL7 testing tools. kevspett General Discussion 3 08-20-2007 03:13 PM
app for injecting data to LLP Listener for testing mcheck Development 3 01-23-2007 09:18 PM
Testing Mirth with bulk messages nshaik Support 5 09-26-2006 06:44 AM


All times are GMT -8. The time now is 03:33 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Mirth Corporation