pivotal/jasmine — Issue #153: Implement aroundEach
Author: searls
Created: 2011-10-28 12:46:30+00:00
State: open

It'd be nice to have an aroundEach function, particularly for situations where something needs to be set up and unwound, and you'd like those two things to sit right next to each other in the code.

Here's the example I just wanted to write:

``` javascript

aroundEach(function(spec){
Timecop.travel(new Date(2011, 10, 28, 11, 45));
spec.run();
Timecop. returnToPresent();
});

```

Not something I'd use everyday, but it can be handy once in a while. (Referenced lib is [Timecop.js](https://github.com/jamesarosen/Timecop.js))