YUI 2.4.0 has been released
As announced earlier today, YUI 2.4.0 has been released. I’ve contributed this time around in two areas.
First, I did a major overhaul of YUI Test to allow for asynchronous tests. All tests now run asynchronously, which eliminates long-running script errors that may occur with large test suites. This asynchronous behavior also allows for tests to wait before continuing, which means you can wait for an event to occur, wait for data to be returned from the server, or wait a predefined amount of time before continuing the test. You can check out the examples and documentation for information on how to get that working.
My second contribution to YUI this release is in the new profiler. The profiler allows you to specify particular functions for measurement, collecting information about the number of calls as well as average, min, and maximum execution time. There is no user interface for the profiler, but it can be really useful in doing performance testing on top of YUI Test. There are plans for a user interface in a later release.
This release was a lot of work for myself and the other YUI authors, but I think you’ll be very pleased with the results.
Disclaimer: Any viewpoints and opinions expressed in this article are those of Nicholas C. Zakas and do not, in any way, reflect those of my employer, my colleagues, Wrox Publishing, O'Reilly Publishing, or anyone else. I speak only for myself, not for them.
Both comments and pings are currently closed.




2 Comments
While I haven’t experimented much with the YUI Test utility, it’s great that you’ve contributed to a growing area in frontend development; Testing! It would be nice to see the rest of YUI shipped with each component tested using this test utility ala "dog food" style. Even further more, it would cool to see each component run through a profiler just as an upfront policy showing "here’s our own stuff getting profiled by our own profiler."
Overall, I’m very pleased with this release and happy with all the hard work the entire team has put into it.
Dustin Diaz on December 5th, 2007 at 3:08 am
Hey Dustin, YUI actually does ship with unit tests for most components. When you download the zip file, look in yui/tests. There are individual files for many components, and an overall YUI.html file that runs all of the other test files.
We (heart) dogfood.
Nicholas C. Zakas on December 5th, 2007 at 1:59 pm
Comments are automatically closed after 14 days.