mack_ruby_core_extensions 0.1.23 → 0.1.24
Sign up to get free protection for your applications and to get access to all the features.
- data/doc/classes/Array.html +465 -0
- data/doc/classes/Class.html +233 -0
- data/doc/classes/Float.html +148 -0
- data/doc/classes/Hash.html +233 -0
- data/doc/classes/Kernel.html +184 -0
- data/doc/classes/Mack/Utils/Inflector.html +422 -0
- data/doc/classes/Math.html +188 -0
- data/doc/classes/MethodNotImplemented.html +155 -0
- data/doc/classes/Module.html +203 -0
- data/doc/classes/NilClass.html +151 -0
- data/doc/classes/Object.html +472 -0
- data/doc/classes/String.html +977 -0
- data/doc/classes/Symbol.html +148 -0
- data/doc/created.rid +1 -0
- data/doc/files/README.html +151 -0
- data/doc/files/lib/extensions/array_rb.html +101 -0
- data/doc/files/lib/extensions/class_rb.html +101 -0
- data/doc/files/lib/extensions/float_rb.html +101 -0
- data/doc/files/lib/extensions/hash_rb.html +108 -0
- data/doc/files/lib/extensions/kernel_rb.html +109 -0
- data/doc/files/lib/extensions/math_rb.html +101 -0
- data/doc/files/lib/extensions/method_not_implemented_rb.html +108 -0
- data/doc/files/lib/extensions/module_rb.html +101 -0
- data/doc/files/lib/extensions/nil_rb.html +101 -0
- data/doc/files/lib/extensions/object_rb.html +101 -0
- data/doc/files/lib/extensions/string_rb.html +108 -0
- data/doc/files/lib/extensions/symbol_rb.html +101 -0
- data/doc/files/lib/mack_ruby_core_extensions_rb.html +101 -0
- data/doc/files/lib/utils/inflections_rb.html +101 -0
- data/doc/files/lib/utils/inflector_rb.html +108 -0
- data/doc/files/lib/utils/options_merger_rb.html +101 -0
- data/doc/fr_class_index.html +39 -0
- data/doc/fr_file_index.html +43 -0
- data/doc/fr_method_index.html +97 -0
- data/doc/index.html +24 -0
- data/doc/rdoc-style.css +208 -0
- data/lib/extensions/hash.rb +0 -13
- data/lib/extensions/object.rb +4 -0
- data/lib/mack_ruby_core_extensions.rb +1 -1
- data/lib/utils/options_merger.rb +27 -0
- data/test/extensions/hash_test.rb +0 -14
- data/test/extensions/object_test.rb +16 -0
- data/test/test_helper.rb +16 -0
- metadata +40 -3
@@ -38,4 +38,20 @@ class ObjectTest < Test::Unit::TestCase
|
|
38
38
|
assert_equal ["Animals", "Dog"], poodle.namespaces
|
39
39
|
end
|
40
40
|
|
41
|
+
def test_with_options
|
42
|
+
route = Route.new
|
43
|
+
route.with_options(:controller => :users) do |r|
|
44
|
+
r.add(:action => :index)
|
45
|
+
end
|
46
|
+
assert_equal route.list.size, 1
|
47
|
+
assert_equal({:controller => :users, :action => :index}, route.list.first)
|
48
|
+
|
49
|
+
route.with_options(:controller => :posts) do |r|
|
50
|
+
r.add(:action => :new)
|
51
|
+
end
|
52
|
+
assert_equal route.list.size, 2
|
53
|
+
assert_equal({:controller => :users, :action => :index}, route.list.first)
|
54
|
+
assert_equal({:controller => :posts, :action => :new}, route.list.last)
|
55
|
+
end
|
56
|
+
|
41
57
|
end
|
data/test/test_helper.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mack_ruby_core_extensions
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.24
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- markbates
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2008-05-
|
12
|
+
date: 2008-05-07 00:00:00 -04:00
|
13
13
|
default_executable:
|
14
14
|
dependencies: []
|
15
15
|
|
@@ -37,7 +37,44 @@ files:
|
|
37
37
|
- lib/mack_ruby_core_extensions.rb
|
38
38
|
- lib/utils/inflections.rb
|
39
39
|
- lib/utils/inflector.rb
|
40
|
+
- lib/utils/options_merger.rb
|
40
41
|
- README
|
42
|
+
- doc/classes/Array.html
|
43
|
+
- doc/classes/Class.html
|
44
|
+
- doc/classes/Float.html
|
45
|
+
- doc/classes/Hash.html
|
46
|
+
- doc/classes/Kernel.html
|
47
|
+
- doc/classes/Mack/Utils/Inflector.html
|
48
|
+
- doc/classes/Math.html
|
49
|
+
- doc/classes/MethodNotImplemented.html
|
50
|
+
- doc/classes/Module.html
|
51
|
+
- doc/classes/NilClass.html
|
52
|
+
- doc/classes/Object.html
|
53
|
+
- doc/classes/String.html
|
54
|
+
- doc/classes/Symbol.html
|
55
|
+
- doc/created.rid
|
56
|
+
- doc/files/lib/extensions/array_rb.html
|
57
|
+
- doc/files/lib/extensions/class_rb.html
|
58
|
+
- doc/files/lib/extensions/float_rb.html
|
59
|
+
- doc/files/lib/extensions/hash_rb.html
|
60
|
+
- doc/files/lib/extensions/kernel_rb.html
|
61
|
+
- doc/files/lib/extensions/math_rb.html
|
62
|
+
- doc/files/lib/extensions/method_not_implemented_rb.html
|
63
|
+
- doc/files/lib/extensions/module_rb.html
|
64
|
+
- doc/files/lib/extensions/nil_rb.html
|
65
|
+
- doc/files/lib/extensions/object_rb.html
|
66
|
+
- doc/files/lib/extensions/string_rb.html
|
67
|
+
- doc/files/lib/extensions/symbol_rb.html
|
68
|
+
- doc/files/lib/mack_ruby_core_extensions_rb.html
|
69
|
+
- doc/files/lib/utils/inflections_rb.html
|
70
|
+
- doc/files/lib/utils/inflector_rb.html
|
71
|
+
- doc/files/lib/utils/options_merger_rb.html
|
72
|
+
- doc/files/README.html
|
73
|
+
- doc/fr_class_index.html
|
74
|
+
- doc/fr_file_index.html
|
75
|
+
- doc/fr_method_index.html
|
76
|
+
- doc/index.html
|
77
|
+
- doc/rdoc-style.css
|
41
78
|
has_rdoc: true
|
42
79
|
homepage: http://www.mackframework.com
|
43
80
|
post_install_message:
|
@@ -66,7 +103,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
66
103
|
requirements: []
|
67
104
|
|
68
105
|
rubyforge_project: magrathea
|
69
|
-
rubygems_version: 1.
|
106
|
+
rubygems_version: 1.1.1
|
70
107
|
signing_key:
|
71
108
|
specification_version: 2
|
72
109
|
summary: mack_ruby_core_extensions
|