Articles

Syspec: System Specifications & Tests using a Rake-like batch file

Syspec lets you write a batch file a lot like a Rake file, but in common HTTP-style language, to test the existence and proper functioning of all the domains, subdomains, their pages and responses. This project is still very much in its infancy, but I decided to get it out there to get some feedback while I use it to track production servers. This is a sample Syspecfile:

ANSI Strings (2nd Edition)

I had a couple of instances where I was adding to the ANSI_CODES constant and creating all sorts of ugly errors. Then a script of mine whispered in my ear its desire for meta-aliases. That prompted a small rewrite of the library.

ANSI Strings: your fun-loving, colourful pal (quick-fix colour library)

You can make your command line interface look a little better than just a bungle of white on black (or however you or your users set your terminal). In my on-going development of a few little open source projects, all of them with CLIs, I abstracted this cute addition to the Ruby snippets junkyard and decided to air it.

With it, you can wrap any string with ANSI codes like this:

After Rails Edge Reston

Well, one more Rails Edge conference came to a close yesterday. This was an especially fun conference, with a lot of great people and some really interesting new material by my fellow speakers. The feedback has been excellent, really hammering home what’s been becoming more and more obvious – this conference format really works.

So, my thanks to those of you who made the conference such a success – the attendees!

After my presentation on Building UI Frameworks, I received a large amount

MicroTest 1.3 / MicroStub 1.1: still under 4KB

MicroTest has had a few tweaks, making it more brief and efficient at what it does. Also, I added a setup and teardown interface which can be used. For example, I removed the use of ObjectSpace and squeezed a few percent of performance just from that. On my 1.83GHz, the 6 tests of the self test now consistently take around 500 microseconds (or 0.0005 seconds). Pretty nippy.

MicroTest 1.2 & MicroStub 1.0: Your microscopic testing pals

Just after writing the previous post, I discovered the need for a little bit of method stubbing and promptly fell upon the task with MicroStyle1. Also, I will officially keep MicroTest under 4 kilobytes2.

MicroTest just got smaller

My little library (the smallest ever?) for bootstrapping and lightning-fast testing has just become smaller. I changed the interface a little: now everything is dependent on method name! So you still have two tests, one which expects true and the other false, and which one is determined by using ‘def should_’ or ‘def should_not_’. Oh happy days!

Ch-Ch-Ch-Chia!

I’ve never had long hair. I grew up in a family where haircuts where performed on a nearly flawless bi-weekly schedule, and my service in the Air Force really put the nail in the coffin – even the thought of having hair over my ears and down my neck makes me a little crazy, not to mention a bit itchy.

Regardless, as of today I am resolved to grow my hair to a minimum length of at least 10 inches.

Surprise 10min Benchmark: eval, class_eval, instance_eval, define_method, bind

What is the fastest way to dynamically define a method? define_method? class_eval? instance_eval? With strings or procs? Maybe we can pull out some arcane magic and use instance_method and bind (depending on what we want to do).

Introducing: MicroTest

Something I cooked up in an hour for bootstrap testing a testing framework.

If anyone actually wants me to maintain it, just give a shout and I’ll gemify it.

Shoes app included XML-RPC Client | Rails Fire

Shoes app included XML-RPC Client

Send to friend

I read RUBIMA (Japanese Rubyist Magazine), Introduce Standard Library #1 XMLRPC4R, Oct. 2005. This is not a new article, but is still cool!So, I came up with an idea to use XMLRPC4R for Andrew O'Brien's interesting idea, AndrewO/assert_acceptable.# sample78-3.pngLook at a tiny note and happy hacking with Shoes! :-Dashbb

Images: