fixturease 0.2 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +1 -1
- data/bin/fixturease.rb +6 -5
- metadata +2 -2
data/Rakefile
CHANGED
data/bin/fixturease.rb
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#! /usr/bin/env ruby
|
2
|
-
unless $0.match /^irb
|
2
|
+
unless $0.match /^irb(\.bat|\.cmd)?$/
|
3
3
|
exec "irb -I #{File.dirname(__FILE__)} -r fixturease --simple-prompt"
|
4
4
|
else
|
5
5
|
ENV['RAILS_ENV'] ||= 'test'
|
@@ -12,11 +12,12 @@ else
|
|
12
12
|
alias_method :save_orig, :save
|
13
13
|
@@fixtures = {}
|
14
14
|
def save
|
15
|
-
save_orig
|
16
|
-
|
17
|
-
|
15
|
+
returning result=save_orig do
|
16
|
+
@@fixtures[self.class] ||= {}
|
17
|
+
@@fixtures[self.class][self.id] = self unless self.new_record?
|
18
|
+
end
|
18
19
|
end
|
19
|
-
|
20
|
+
|
20
21
|
def self.fixturease_fixtures
|
21
22
|
@@fixtures
|
22
23
|
end
|
metadata
CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.9.0
|
|
3
3
|
specification_version: 1
|
4
4
|
name: fixturease
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version:
|
7
|
-
date: 2007-01-
|
6
|
+
version: 0.2.1
|
7
|
+
date: 2007-01-19 00:00:00 +02:00
|
8
8
|
summary: Easy fixture creation tool
|
9
9
|
require_paths:
|
10
10
|
- lib
|