「2013/7/8にRSpec 2.14がリリースされた」の、ファーストインプレッション

RSpec 2.14 is released!: http://myronmars.to/n/dev-blog/2013/07/rspec-2-14-is-released ってことで、ざっとリリースノートを読んで、びびっときたのはこれだ!!

Core: Shared example groups are scoped to the context they are defined in

Before 2.14, shared example groups were stored in a global hash, could be defined in any context, and could be used from any context. In 2.14, this has changed: shared example groups are now scoped to the context they are defined in.

ようは、「shared_examplesやshared_contextがスコープをもったよ♪それらが定義されたスコープに閉じてるから、名前の衝突が起きなくなったよ〜♥」ってことです。
私にとってはこの仕様変更はとってもうれしいです。いちいちshared_examplesにユニークな名前をつけるとかね〜、面倒でしたよ、ほんと。

ということで、興味がある方はRSpec 2.14にアップデートしてみてくださいね〜。

--- 参考URL

--- PR広告
記事を読んでくださり、ありがとうございます。もしよろしければ、この記事の著者が開発・運営している無料のカクテルレシピ提供サービス「かくってる?」をお試しください。