joinfix 1.0.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,7 @@
1
1
  ENV["RAILS_ENV"] = "test"
2
2
  require File.expand_path(File.dirname(__FILE__) + "/../config/environment")
3
- require 'test_help'
4
- require 'gemdev'
5
- require 'joinfix'
3
+ require 'test_help'
4
+ require File.dirname(__FILE__) + '/../../lib/joinfix'
6
5
 
7
6
  class Test::Unit::TestCase
8
7
  # Transactional fixtures accelerate your tests by wrapping each test method
@@ -1,8 +1,7 @@
1
- require 'gemdev'
2
- require 'test/unit/subsets'
1
+ require 'tap/test/subset_methods'
3
2
  require 'active_record'
4
3
  require 'active_record/fixtures'
5
- require 'joinfix'
4
+ require File.dirname(__FILE__) + '/../lib/joinfix'
6
5
  require 'tempfile'
7
6
 
8
7
  # Try to extablish a connection to the configured database
@@ -34,6 +33,12 @@ class Test::Unit::TestCase
34
33
  end
35
34
 
36
35
  class Test::Unit::TestCase
36
+ include Tap::Test::SubsetMethods
37
+
38
+ condition(:connected) do
39
+ ActiveRecord::Base.connected?
40
+ end
41
+
37
42
  def setup
38
43
  migration.up if connected?
39
44
  end
@@ -50,7 +55,7 @@ class Test::Unit::TestCase
50
55
  end
51
56
 
52
57
  def connected?
53
- ActiveRecord::Base.connected?
58
+ satisfied?(:connected)
54
59
  end
55
60
 
56
61
  def migration
@@ -88,13 +93,13 @@ class Test::Unit::TestCase
88
93
  end
89
94
 
90
95
  def database_test(&block)
91
- switch_test(connected?) do
96
+ condition_test(:connected) do
92
97
  yield
93
98
  end
94
99
  end
95
100
 
96
101
  def error_test(type, &block)
97
- switch_test(connected?) do
102
+ condition_test(:connected) do
98
103
  if env('show_errors')
99
104
  begin
100
105
  yield
@@ -1,10 +1,7 @@
1
- $:.unshift File.join(File.dirname(__FILE__), '../lib')
1
+ require 'test/unit'
2
2
 
3
3
  puts %{
4
4
  NOTE! The joinfix tests are not run through this test suite
5
5
  because they must connect to a database. See TEST_README
6
6
  for details and instructions on running the joinfix tests.
7
- }
8
- #
9
- #ENV["ALL"] = 'true'
10
- #Dir.glob("./**/*_test.rb").each {|test| require test}
7
+ }
metadata CHANGED
@@ -1,33 +1,37 @@
1
1
  --- !ruby/object:Gem::Specification
2
- rubygems_version: 0.9.2
3
- specification_version: 1
4
2
  name: joinfix
5
3
  version: !ruby/object:Gem::Version
6
- version: 1.0.0
7
- date: 2007-06-28 00:00:00 -06:00
8
- summary: A reflection-based solution to the fixture join problem.
9
- require_paths:
10
- - lib
11
- email: simon.chiang@uchsc.edu
12
- homepage: http://rubyforge.org/projects/joinfix/
13
- rubyforge_project:
14
- description:
15
- autorequire: joinfix
16
- default_executable:
17
- bindir: bin
18
- has_rdoc: true
19
- required_ruby_version: !ruby/object:Gem::Version::Requirement
20
- requirements:
21
- - - ">"
22
- - !ruby/object:Gem::Version
23
- version: 0.0.0
24
- version:
4
+ version: 1.0.1
25
5
  platform: ruby
26
- signing_key:
27
- cert_chain:
28
- post_install_message:
29
6
  authors:
30
7
  - Simon Chiang
8
+ autorequire: joinfix
9
+ bindir: bin
10
+ cert_chain: []
11
+
12
+ date: 2007-12-13 00:00:00 -07:00
13
+ default_executable:
14
+ dependencies:
15
+ - !ruby/object:Gem::Dependency
16
+ name: activerecord
17
+ version_requirement:
18
+ version_requirements: !ruby/object:Gem::Requirement
19
+ requirements:
20
+ - - ">="
21
+ - !ruby/object:Gem::Version
22
+ version: 1.15.1
23
+ version:
24
+ description:
25
+ email: simon.chiang@uchsc.edu
26
+ executables: []
27
+
28
+ extensions: []
29
+
30
+ extra_rdoc_files:
31
+ - README
32
+ - MIT-LICENSE
33
+ - TEST_README
34
+ - History
31
35
  files:
32
36
  - test/belongs_to_polymorphic_test.rb
33
37
  - test/belongs_to_test.rb
@@ -139,8 +143,8 @@ files:
139
143
  - rails/test/fixtures/inner_children.yml
140
144
  - rails/test/fixtures/nested_children.yml
141
145
  - rails/test/fixtures/nested_parents.yml
142
- - rails/test/fixtures/users.yml
143
146
  - rails/test/fixtures/user_groups.yml
147
+ - rails/test/fixtures/users.yml
144
148
  - rails/test/functional
145
149
  - rails/test/integration
146
150
  - rails/test/mocks
@@ -161,30 +165,35 @@ files:
161
165
  - README
162
166
  - MIT-LICENSE
163
167
  - TEST_README
164
- test_files:
165
- - test/joinfix_test_suite.rb
168
+ - History
169
+ has_rdoc: true
170
+ homepage: http://rubyforge.org/projects/joinfix/
171
+ post_install_message:
166
172
  rdoc_options:
167
173
  - --title
168
174
  - JoinFix
169
175
  - --main
170
176
  - README
171
- extra_rdoc_files:
172
- - README
173
- - MIT-LICENSE
174
- - TEST_README
175
- executables: []
176
-
177
- extensions: []
178
-
177
+ require_paths:
178
+ - lib
179
+ required_ruby_version: !ruby/object:Gem::Requirement
180
+ requirements:
181
+ - - ">="
182
+ - !ruby/object:Gem::Version
183
+ version: "0"
184
+ version:
185
+ required_rubygems_version: !ruby/object:Gem::Requirement
186
+ requirements:
187
+ - - ">="
188
+ - !ruby/object:Gem::Version
189
+ version: "0"
190
+ version:
179
191
  requirements: []
180
192
 
181
- dependencies:
182
- - !ruby/object:Gem::Dependency
183
- name: activerecord
184
- version_requirement:
185
- version_requirements: !ruby/object:Gem::Version::Requirement
186
- requirements:
187
- - - ">="
188
- - !ruby/object:Gem::Version
189
- version: 1.15.1
190
- version:
193
+ rubyforge_project:
194
+ rubygems_version: 0.9.5
195
+ signing_key:
196
+ specification_version: 2
197
+ summary: A reflection-based solution to the fixture join problem.
198
+ test_files:
199
+ - test/joinfix_test_suite.rb