About a month ago, I published a ProcessMaker gem for Ruby and had some traction with almost 500 downloads in three weeks. But what can the library do? This post will show you a little trick to take advantage of this gem.
200 cases at once? No problem, bro
So, let’s say we want to start 200 cases for any crazy reason. Perhaps you want to do some load testing on the application and the best way to accomplish this is to generate cases.
Ruby is your buddy
First, you’ll need to have Ruby installed. I won’t go into details on how to set it up, but once you have it, go to your terminal or command line and type this:
gem install processmaker
(This works on Windows and LINUX/UNIX)
Create a file: pm.rb
And make sure you have this:
wsdl: # your PM web service url
user_id: # username
password: # password
(1..200).each do |c|
process_list: # ID process
task_list: # TASK list
Did you see the (1..200) block almost at the end? That will loop through the new_case method 200 times. No more, no less.
And there you go! A simple trick that shows what you can accomplish with the ProcessMaker Gem.
I got a question!
Sure, you can find me on twitter: @yamilurbina