MetaSkills.net

Autotest Playlist For Red/Green Feedback

Posted On: April 6th, 2008 by kencollins

Here is how to get a playlist of sounds that will be hooked to both your autotest :red and :green callbacks. Basically this gives you a folder of sounds that are played one after another, in a loop, as your tests pass or fail. See this move below for a quick example.

Step 1: Install QTPlay from MacPorts

sudo port install qtplay

Step 2: Download My Autotest Playlist Files

cd ~
curl -O http://www.metaskills.net/files/autotest_playlist.tar
tar -xf autotest_playlist.tar
mv autotest_playlist .autotest_playlist && rm autotest_playlist.tar

Step 3: Modify Your .autotest File

User your favorite editor to open your ~/.autotest file. And add this code below to it. Now you should be setup to have your own playlist of sounds that play using the qtplay binary installed above. If you want to play around with the sounds, then open ~/.autotest_playlist/sounds and start swapping out sounds. By the way, I made the :initialize and :quit sounds using the new Alex voice in Leopard. I hijacked some text to speech and then ran an audio tool called WavePad to speed change, flange, and chorus the voice a little bit.

1
2

require '~/.autotest_playlist/playlist'

Credits:

The idea for this came from FoxWorks. Shouts out "Thank You".

Mike McKinney

  HOMEPAGE  | April 6th, 2008 at 09:59 PM
Mike McKinney Very nice Ken!

Ken Collins

  HOMEPAGE  | April 7th, 2008 at 09:41 AM
Ken Collins Thanks Mike! My first cut at this was just picking a file randomly to play from the list, but duplicates in a list of 20 or 30 red sounds was bugging me. Since autotest is not a script but just constantly runs, it was easy to hack in a class attribute that kept the state of the index.

Rob Olson

  HOMEPAGE  | June 21st, 2008 at 11:37 PM
Rob Olson Hi Ken, Sweet upgrade. I'm really enjoying the autotest + sound. I just wanted to mention that I do not believe require 'active_support' is necessary in the playlist.rb script. I removed it out and it seems to be working still.

Ken Collins

  HOMEPAGE  | June 22nd, 2008 at 06:21 PM
Ken Collins Awesome! Thanks for letting me know.

Leave a Comment

Name (required)
Email (will not be published)
Website
Comment