Permalink
Browse files

Adding runtime access to version file

  • Loading branch information...
1 parent 43f3edc commit 970ee8106cf2b67da974bab6ccaa11cda2ce3a37 @trydionel committed Sep 19, 2010
Showing with 6 additions and 0 deletions.
  1. +2 −0 lib/web_fixtures/base.rb
  2. +4 −0 spec/web_fixtures/base_spec.rb
View
@@ -1,4 +1,6 @@
module WebFixtures
+
+ Version = File.read(File.join(File.dirname(__FILE__), '..', '..', 'VERSION'))
def self.generate(&block)
WebFixtures::Base.new(&block)
@@ -4,6 +4,10 @@
it { should be_a(Array) }
its(:dsl) { should be_a(WebFixtures::DSL) }
+
+ it "should expose a version number" do
+ WebFixtures::Version.should == File.read(File.join(File.dirname(__FILE__), '..', '..', 'VERSION'))
+ end
describe "#run!" do

0 comments on commit 970ee81

Please sign in to comment.