module-cluster 1.4.0 → 1.4.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (50) hide show
  1. data/README.md +66 -29
  2. data/README.rdoc +66 -29
  3. data/lib/module-cluster.rb +18 -0
  4. data/lib/module-cluster/ModuleCluster.rb +2 -7
  5. data/lib/module-cluster/ModuleCluster/Define/Block.rb +4 -4
  6. data/lib/module-cluster/ModuleCluster/Define/Block/Class.rb +11 -8
  7. data/lib/module-cluster/ModuleCluster/Define/Block/ClassOrInstance.rb +19 -12
  8. data/lib/module-cluster/ModuleCluster/Define/Block/ClassOrModule.rb +19 -12
  9. data/lib/module-cluster/ModuleCluster/Define/Block/ClassOrModuleOrInstance.rb +19 -12
  10. data/lib/module-cluster/ModuleCluster/Define/Block/Instance.rb +3 -2
  11. data/lib/module-cluster/ModuleCluster/Define/Block/Module.rb +11 -8
  12. data/lib/module-cluster/ModuleCluster/Define/Block/ModuleOrInstance.rb +19 -12
  13. data/lib/module-cluster/ModuleCluster/Define/ClassCluster.rb +39 -46
  14. data/lib/module-cluster/ModuleCluster/Define/ClassOrInstanceCluster.rb +34 -33
  15. data/lib/module-cluster/ModuleCluster/Define/Cluster.rb +31 -42
  16. data/lib/module-cluster/ModuleCluster/Define/ClusterCascades.rb +53 -62
  17. data/lib/module-cluster/ModuleCluster/Define/ClusterCascadesToClass.rb +49 -60
  18. data/lib/module-cluster/ModuleCluster/Define/ClusterCascadesToModule.rb +49 -60
  19. data/lib/module-cluster/ModuleCluster/Define/InstanceCluster.rb +3 -4
  20. data/lib/module-cluster/ModuleCluster/Define/ModuleCluster.rb +39 -46
  21. data/lib/module-cluster/ModuleCluster/Define/ModuleOrClassCluster.rb +55 -54
  22. data/lib/module-cluster/ModuleCluster/Define/ModuleOrInstanceCluster.rb +34 -33
  23. data/lib/module-cluster/_private_/ModuleCluster/CascadeFeatures.rb +4 -4
  24. data/lib/module-cluster/_private_/ModuleCluster/CascadeFeatures/ClusterStack.rb +1 -1
  25. data/lib/module-cluster/_private_/ModuleCluster/CascadeFeatures/PerformCascades.rb +64 -46
  26. data/lib/module-cluster/_private_/ModuleCluster/ClusterStack.rb +7 -5
  27. data/lib/module-cluster/_private_/ModuleCluster/ClusterStack/Block.rb +3 -3
  28. data/lib/module-cluster/_private_/ModuleCluster/ClusterStack/Block/Class.rb +2 -2
  29. data/lib/module-cluster/_private_/ModuleCluster/ClusterStack/Block/Instance.rb +1 -1
  30. data/lib/module-cluster/_private_/ModuleCluster/ClusterStack/Block/Module.rb +2 -2
  31. data/lib/module-cluster/_private_/ModuleCluster/ClusterStack/Block/Set.rb +4 -1
  32. data/lib/module-cluster/_private_/ModuleCluster/ClusterStack/Extends.rb +45 -13
  33. data/lib/module-cluster/_private_/ModuleCluster/ClusterStack/Includes.rb +36 -10
  34. data/lib/module-cluster/_private_/ModuleCluster/ClusterStack/PrependsExtends.rb +47 -15
  35. data/lib/module-cluster/_private_/ModuleCluster/ClusterStack/PrependsIncludes.rb +38 -12
  36. data/lib/module-cluster/_private_/ModuleCluster/ClusterStack/Set.rb +29 -1
  37. data/lib/module-cluster/_private_/ModuleCluster/ExtendForCascade.rb +8 -3
  38. data/spec/ModuleCluster/Define/ClassCluster_spec.rb +18 -18
  39. data/spec/ModuleCluster/Define/ClassOrInstanceCluster_spec.rb +10 -10
  40. data/spec/ModuleCluster/Define/ClusterCascadesToClass_spec.rb +18 -18
  41. data/spec/ModuleCluster/Define/ClusterCascadesToModule_spec.rb +18 -18
  42. data/spec/ModuleCluster/Define/ClusterCascades_spec.rb +18 -18
  43. data/spec/ModuleCluster/Define/Cluster_spec.rb +18 -18
  44. data/spec/ModuleCluster/Define/InstanceCluster_spec.rb +2 -2
  45. data/spec/ModuleCluster/Define/ModuleCluster_spec.rb +18 -18
  46. data/spec/ModuleCluster/Define/ModuleOrClassCluster_spec.rb +18 -18
  47. data/spec/ModuleCluster/Define/ModuleOrInstanceCluster_spec.rb +10 -10
  48. data/spec/ModuleCluster_spec.rb +5 -5
  49. data/spec/_private_/ModuleCluster/CascadeFeatures/PerformCascades_spec.rb +110 -2
  50. metadata +2 -2
@@ -2,11 +2,11 @@
2
2
  module ModuleCluster::ClusterStack::PrependsExtends
3
3
 
4
4
  #############################
5
- # prepending_extend_hooks #
5
+ # prepend_extend_hooks #
6
6
  #############################
7
7
 
8
- def prepending_extend_hooks
9
- return @prepending_extend_hooks ||= Array.new
8
+ def prepend_extend_hooks
9
+ return @prepend_extend_hooks ||= ::ModuleCluster::ClusterStack::Set::MultiSetProxy.new
10
10
  end
11
11
 
12
12
  ##############################
@@ -14,7 +14,9 @@ module ModuleCluster::ClusterStack::PrependsExtends
14
14
  ##############################
15
15
 
16
16
  def extend_prepends_includes( module_instance, method, includes, runtime_includes_block )
17
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :include, includes, runtime_includes_block ) )
17
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :include, includes, runtime_includes_block )
18
+ prepend_extend_hooks.push( new_set )
19
+ return new_set
18
20
  end
19
21
 
20
22
  #############################
@@ -22,7 +24,9 @@ module ModuleCluster::ClusterStack::PrependsExtends
22
24
  #############################
23
25
 
24
26
  def extend_prepends_extends( module_instance, method, extends, runtime_extends_block )
25
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :extend, extends, runtime_extends_block ) )
27
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :extend, extends, runtime_extends_block )
28
+ prepend_extend_hooks.push( new_set )
29
+ return new_set
26
30
  end
27
31
 
28
32
  ##########################################
@@ -30,7 +34,9 @@ module ModuleCluster::ClusterStack::PrependsExtends
30
34
  ##########################################
31
35
 
32
36
  def extend_prepends_includes_and_extends( module_instance, method, includes_and_extends, runtime_includes_and_extends_block )
33
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block ) )
37
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block )
38
+ prepend_extend_hooks.push( new_set )
39
+ return new_set
34
40
  end
35
41
 
36
42
  #####################################
@@ -38,7 +44,9 @@ module ModuleCluster::ClusterStack::PrependsExtends
38
44
  #####################################
39
45
 
40
46
  def module_extend_prepends_includes( module_instance, method, includes, runtime_includes_block )
41
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :include, includes, runtime_includes_block ) )
47
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :include, includes, runtime_includes_block )
48
+ prepend_extend_hooks.push( new_set )
49
+ return new_set
42
50
  end
43
51
 
44
52
  ####################################
@@ -46,7 +54,9 @@ module ModuleCluster::ClusterStack::PrependsExtends
46
54
  ####################################
47
55
 
48
56
  def module_extend_prepends_extends( module_instance, method, extends, runtime_extends_block )
49
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :extend, extends, runtime_extends_block ) )
57
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :extend, extends, runtime_extends_block )
58
+ prepend_extend_hooks.push( new_set )
59
+ return new_set
50
60
  end
51
61
 
52
62
  #################################################
@@ -54,7 +64,9 @@ module ModuleCluster::ClusterStack::PrependsExtends
54
64
  #################################################
55
65
 
56
66
  def module_extend_prepends_includes_and_extends( module_instance, method, includes_and_extends, runtime_includes_and_extends_block )
57
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block ) )
67
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block )
68
+ prepend_extend_hooks.push( new_set )
69
+ return new_set
58
70
  end
59
71
 
60
72
  ####################################
@@ -62,7 +74,9 @@ module ModuleCluster::ClusterStack::PrependsExtends
62
74
  ####################################
63
75
 
64
76
  def class_extend_prepends_includes( module_instance, method, includes, runtime_includes_block )
65
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :include, includes, runtime_includes_block ) )
77
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :include, includes, runtime_includes_block )
78
+ prepend_extend_hooks.push( new_set )
79
+ return new_set
66
80
  end
67
81
 
68
82
  ###################################
@@ -70,7 +84,9 @@ module ModuleCluster::ClusterStack::PrependsExtends
70
84
  ###################################
71
85
 
72
86
  def class_extend_prepends_extends( module_instance, method, extends, runtime_extends_block )
73
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :extend, extends, runtime_extends_block ) )
87
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :extend, extends, runtime_extends_block )
88
+ prepend_extend_hooks.push( new_set )
89
+ return new_set
74
90
  end
75
91
 
76
92
  ################################################
@@ -78,7 +94,9 @@ module ModuleCluster::ClusterStack::PrependsExtends
78
94
  ################################################
79
95
 
80
96
  def class_extend_prepends_includes_and_extends( module_instance, method, includes_and_extends, runtime_includes_and_extends_block )
81
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block ) )
97
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block )
98
+ prepend_extend_hooks.push( new_set )
99
+ return new_set
82
100
  end
83
101
 
84
102
  #######################################
@@ -86,7 +104,9 @@ module ModuleCluster::ClusterStack::PrependsExtends
86
104
  #######################################
87
105
 
88
106
  def instance_extend_prepends_includes( module_instance, method, includes, runtime_includes_block )
89
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :instance, :include, includes, runtime_includes_block ) )
107
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :instance, :include, includes, runtime_includes_block )
108
+ prepend_extend_hooks.push( new_set )
109
+ return new_set
90
110
  end
91
111
 
92
112
  ######################################
@@ -94,7 +114,9 @@ module ModuleCluster::ClusterStack::PrependsExtends
94
114
  ######################################
95
115
 
96
116
  def instance_extend_prepends_extends( module_instance, method, extends, runtime_extends_block )
97
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :instance, :extend, extends, runtime_extends_block ) )
117
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :instance, :extend, extends, runtime_extends_block )
118
+ prepend_extend_hooks.push( new_set )
119
+ return new_set
98
120
  end
99
121
 
100
122
  ###################################################
@@ -102,7 +124,17 @@ module ModuleCluster::ClusterStack::PrependsExtends
102
124
  ###################################################
103
125
 
104
126
  def instance_extend_prepends_includes_and_extends( module_instance, method, includes_and_extends, runtime_includes_and_extends_block )
105
- prepending_extend_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :instance, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block ) )
127
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :instance, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block )
128
+ prepend_extend_hooks.push( new_set )
129
+ return new_set
130
+ end
131
+
132
+ ##############################
133
+ # has_prepend_extend_hook? #
134
+ ##############################
135
+
136
+ def has_prepend_extend_hook?( description )
137
+ return prepend_extend_hooks.hooks_with( description ) || false
106
138
  end
107
139
 
108
140
  end
@@ -2,11 +2,11 @@
2
2
  module ModuleCluster::ClusterStack::PrependsIncludes
3
3
 
4
4
  ##############################
5
- # prepending_include_hooks #
5
+ # prepend_include_hooks #
6
6
  ##############################
7
7
 
8
- def prepending_include_hooks
9
- return @prepending_include_hooks ||= Array.new
8
+ def prepend_include_hooks
9
+ return @prepend_include_hooks ||= ::ModuleCluster::ClusterStack::Set::MultiSetProxy.new
10
10
  end
11
11
 
12
12
  ###############################
@@ -14,7 +14,9 @@ module ModuleCluster::ClusterStack::PrependsIncludes
14
14
  ###############################
15
15
 
16
16
  def include_prepends_includes( module_instance, method, includes, runtime_includes_block )
17
- prepending_include_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :include, includes, runtime_includes_block ) )
17
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :include, includes, runtime_includes_block )
18
+ prepend_include_hooks.push( new_set )
19
+ return new_set
18
20
  end
19
21
 
20
22
  ##############################
@@ -22,7 +24,9 @@ module ModuleCluster::ClusterStack::PrependsIncludes
22
24
  ##############################
23
25
 
24
26
  def include_prepends_extends( module_instance, method, extends, runtime_extends_block )
25
- prepending_include_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :extend, extends, runtime_extends_block ) )
27
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :extend, extends, runtime_extends_block )
28
+ prepend_include_hooks.push( new_set )
29
+ return new_set
26
30
  end
27
31
 
28
32
  ###########################################
@@ -30,7 +34,9 @@ module ModuleCluster::ClusterStack::PrependsIncludes
30
34
  ###########################################
31
35
 
32
36
  def include_prepends_includes_and_extends( module_instance, method, includes_and_extends, runtime_includes_and_extends_block )
33
- prepending_include_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block ) )
37
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :all, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block )
38
+ prepend_include_hooks.push( new_set )
39
+ return new_set
34
40
  end
35
41
 
36
42
  ######################################
@@ -38,7 +44,9 @@ module ModuleCluster::ClusterStack::PrependsIncludes
38
44
  ######################################
39
45
 
40
46
  def module_include_prepends_includes( module_instance, method, includes, runtime_includes_block )
41
- prepending_include_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :include, includes, runtime_includes_block ) )
47
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :include, includes, runtime_includes_block )
48
+ prepend_include_hooks.push( new_set )
49
+ return new_set
42
50
  end
43
51
 
44
52
  #####################################
@@ -46,7 +54,9 @@ module ModuleCluster::ClusterStack::PrependsIncludes
46
54
  #####################################
47
55
 
48
56
  def module_include_prepends_extends( module_instance, method, extends, runtime_extends_block )
49
- prepending_include_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :extend, extends, runtime_extends_block ) )
57
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :extend, extends, runtime_extends_block )
58
+ prepend_include_hooks.push( new_set )
59
+ return new_set
50
60
  end
51
61
 
52
62
  ##################################################
@@ -54,7 +64,9 @@ module ModuleCluster::ClusterStack::PrependsIncludes
54
64
  ##################################################
55
65
 
56
66
  def module_include_prepends_includes_and_extends( module_instance, method, includes_and_extends, runtime_includes_and_extends_block )
57
- prepending_include_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block ) )
67
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :module, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block )
68
+ prepend_include_hooks.push( new_set )
69
+ return new_set
58
70
  end
59
71
 
60
72
  #####################################
@@ -62,7 +74,9 @@ module ModuleCluster::ClusterStack::PrependsIncludes
62
74
  #####################################
63
75
 
64
76
  def class_include_prepends_includes( module_instance, method, includes, runtime_includes_block )
65
- prepending_include_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :include, includes, runtime_includes_block ) )
77
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :include, includes, runtime_includes_block )
78
+ prepend_include_hooks.push( new_set )
79
+ return new_set
66
80
  end
67
81
 
68
82
  ####################################
@@ -70,7 +84,9 @@ module ModuleCluster::ClusterStack::PrependsIncludes
70
84
  ####################################
71
85
 
72
86
  def class_include_prepends_extends( module_instance, method, extends, runtime_extends_block )
73
- prepending_include_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :extend, extends, runtime_extends_block ) )
87
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :extend, extends, runtime_extends_block )
88
+ prepend_include_hooks.push( new_set )
89
+ return new_set
74
90
  end
75
91
 
76
92
  #################################################
@@ -78,7 +94,17 @@ module ModuleCluster::ClusterStack::PrependsIncludes
78
94
  #################################################
79
95
 
80
96
  def class_include_prepends_includes_and_extends( module_instance, method, includes_and_extends, runtime_includes_and_extends_block )
81
- prepending_include_hooks.push( ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block ) )
97
+ new_set = ModuleCluster::ClusterStack::Set.new( module_instance, method, :class, :include_and_extend, includes_and_extends, runtime_includes_and_extends_block )
98
+ prepend_include_hooks.push( new_set )
99
+ return new_set
100
+ end
101
+
102
+ ###############################
103
+ # has_prepend_include_hook? #
104
+ ###############################
105
+
106
+ def has_prepend_include_hook?( description )
107
+ return prepend_include_hooks.hooks_with( description ) || false
82
108
  end
83
109
 
84
110
  end
@@ -4,4 +4,32 @@ ModuleCluster::ClusterStack::Set = Struct.new( :dependency_module,
4
4
  :module_class_instance_or_all,
5
5
  :include_or_extend,
6
6
  :modules,
7
- :runtime_includes_or_extends_block )
7
+ :runtime_includes_or_extends_block,
8
+ :suspended,
9
+ :name ) do
10
+
11
+ #############
12
+ # suspend #
13
+ #############
14
+
15
+ def suspend
16
+ suspended = true
17
+ end
18
+
19
+ ############
20
+ # resume #
21
+ ############
22
+
23
+ def resume
24
+ suspended = false
25
+ end
26
+
27
+ ################
28
+ # suspended? #
29
+ ################
30
+
31
+ def suspended?
32
+ return suspended
33
+ end
34
+
35
+ end
@@ -5,11 +5,16 @@ module ModuleCluster::ExtendForCascade
5
5
  # extended #
6
6
  ##############
7
7
 
8
- def extended( class_or_module )
8
+ def extended( module_cluster_module )
9
9
  super
10
- class_or_module.module_eval do
10
+ module_cluster_module.module_eval do
11
+ # when a module-cluster definition module is used to extend a module,
12
+ # define self#extended, self#included, self#append_features, self#extend_object in
13
+ # module_cluster_module ( module extended with module-cluster definition module )
11
14
  extend ModuleCluster::CascadeFeatures
12
- end if class_or_module.is_a?( Module ) and ! class_or_module.is_a?( Class )
15
+ # classes and instances can't cascade through include/extend, so no reason to define
16
+ # unless we have a module
17
+ end if module_cluster_module.is_a?( Module ) and ! module_cluster_module.is_a?( Class )
13
18
  end
14
19
 
15
20
  end
@@ -34,7 +34,7 @@ describe ModuleCluster::Define::ClassCluster do
34
34
  end
35
35
  module Module2
36
36
  end
37
- class_include_also_includes( Module1, Module2 )
37
+ class_include_also_includes( Module1, Module2 ).name = :some_name
38
38
  respond_to?( :included ).should == true
39
39
  module ModuleProof
40
40
  include ModuleCluster::Define::ClassCluster::Mock01
@@ -66,7 +66,7 @@ describe ModuleCluster::Define::ClassCluster do
66
66
  end
67
67
  module Module2
68
68
  end
69
- class_include_also_extends( Module1, Module2 )
69
+ class_include_also_extends( Module1, Module2 ).name = :some_name
70
70
  respond_to?( :included ).should == true
71
71
  module ModuleProof
72
72
  include ModuleCluster::Define::ClassCluster::Mock02
@@ -98,7 +98,7 @@ describe ModuleCluster::Define::ClassCluster do
98
98
  end
99
99
  module Module2
100
100
  end
101
- class_include_also_includes_and_extends( Module1, Module2 )
101
+ class_include_also_includes_and_extends( Module1, Module2 ).name = :some_name
102
102
  respond_to?( :included ).should == true
103
103
  module ModuleProof
104
104
  include ModuleCluster::Define::ClassCluster::Mock03
@@ -130,7 +130,7 @@ describe ModuleCluster::Define::ClassCluster do
130
130
  end
131
131
  module Module2
132
132
  end
133
- class_extend_also_includes( Module1, Module2 )
133
+ class_extend_also_includes( Module1, Module2 ).name = :some_name
134
134
  respond_to?( :extended ).should == true
135
135
  module ModuleProof
136
136
  extend ModuleCluster::Define::ClassCluster::Mock04
@@ -162,7 +162,7 @@ describe ModuleCluster::Define::ClassCluster do
162
162
  end
163
163
  module Module2
164
164
  end
165
- class_extend_also_extends( Module1, Module2 )
165
+ class_extend_also_extends( Module1, Module2 ).name = :some_name
166
166
  respond_to?( :extended ).should == true
167
167
  module ModuleProof
168
168
  extend ModuleCluster::Define::ClassCluster::Mock05
@@ -200,7 +200,7 @@ describe ModuleCluster::Define::ClassCluster do
200
200
  end
201
201
  module Module2
202
202
  end
203
- class_extend_also_includes_and_extends( Module1, Module2 )
203
+ class_extend_also_includes_and_extends( Module1, Module2 ).name = :some_name
204
204
  respond_to?( :extended ).should == true
205
205
  module ModuleProof
206
206
  extend ModuleCluster::Define::ClassCluster::Mock06
@@ -238,7 +238,7 @@ describe ModuleCluster::Define::ClassCluster do
238
238
  end
239
239
  module Module2
240
240
  end
241
- class_include_prepends_includes( Module1, Module2 )
241
+ class_include_prepends_includes( Module1, Module2 ).name = :some_name
242
242
  respond_to?( :append_features ).should == true
243
243
  module ModuleProof
244
244
  include ModuleCluster::Define::ClassCluster::Mock07
@@ -270,7 +270,7 @@ describe ModuleCluster::Define::ClassCluster do
270
270
  end
271
271
  module Module2
272
272
  end
273
- class_include_prepends_extends( Module1, Module2 )
273
+ class_include_prepends_extends( Module1, Module2 ).name = :some_name
274
274
  respond_to?( :append_features ).should == true
275
275
  module ModuleProof
276
276
  include ModuleCluster::Define::ClassCluster::Mock08
@@ -302,7 +302,7 @@ describe ModuleCluster::Define::ClassCluster do
302
302
  end
303
303
  module Module2
304
304
  end
305
- class_include_prepends_includes_and_extends( Module1, Module2 )
305
+ class_include_prepends_includes_and_extends( Module1, Module2 ).name = :some_name
306
306
  respond_to?( :append_features ).should == true
307
307
  module ModuleProof
308
308
  include ModuleCluster::Define::ClassCluster::Mock09
@@ -334,7 +334,7 @@ describe ModuleCluster::Define::ClassCluster do
334
334
  end
335
335
  module Module2
336
336
  end
337
- class_extend_prepends_includes( Module1, Module2 )
337
+ class_extend_prepends_includes( Module1, Module2 ).name = :some_name
338
338
  respond_to?( :extend_object ).should == true
339
339
  module ModuleProof
340
340
  extend ModuleCluster::Define::ClassCluster::Mock10
@@ -366,7 +366,7 @@ describe ModuleCluster::Define::ClassCluster do
366
366
  end
367
367
  module Module2
368
368
  end
369
- class_extend_prepends_extends( Module1, Module2 )
369
+ class_extend_prepends_extends( Module1, Module2 ).name = :some_name
370
370
  respond_to?( :extend_object ).should == true
371
371
  module ModuleProof
372
372
  extend ModuleCluster::Define::ClassCluster::Mock11
@@ -404,7 +404,7 @@ describe ModuleCluster::Define::ClassCluster do
404
404
  end
405
405
  module Module2
406
406
  end
407
- class_extend_prepends_includes_and_extends( Module1, Module2 )
407
+ class_extend_prepends_includes_and_extends( Module1, Module2 ).name = :some_name
408
408
  respond_to?( :extend_object ).should == true
409
409
  module ModuleProof
410
410
  extend ModuleCluster::Define::ClassCluster::Mock12
@@ -442,7 +442,7 @@ describe ModuleCluster::Define::ClassCluster do
442
442
  end
443
443
  module Module2
444
444
  end
445
- class_include_or_extend_also_includes( Module1, Module2 )
445
+ class_include_or_extend_also_includes( Module1, Module2 ).name = :some_name
446
446
  respond_to?( :append_features ).should == true
447
447
  module ModuleProof
448
448
  include ModuleCluster::Define::ClassCluster::Mock13
@@ -490,7 +490,7 @@ describe ModuleCluster::Define::ClassCluster do
490
490
  end
491
491
  module Module2
492
492
  end
493
- class_include_or_extend_also_extends( Module1, Module2 )
493
+ class_include_or_extend_also_extends( Module1, Module2 ).name = :some_name
494
494
  respond_to?( :included ).should == true
495
495
  module ModuleProof
496
496
  include ModuleCluster::Define::ClassCluster::Mock14
@@ -538,7 +538,7 @@ describe ModuleCluster::Define::ClassCluster do
538
538
  end
539
539
  module Module2
540
540
  end
541
- class_include_or_extend_also_includes_and_extends( Module1, Module2 )
541
+ class_include_or_extend_also_includes_and_extends( Module1, Module2 ).name = :some_name
542
542
  respond_to?( :included ).should == true
543
543
  module ModuleProof
544
544
  include ModuleCluster::Define::ClassCluster::Mock15
@@ -586,7 +586,7 @@ describe ModuleCluster::Define::ClassCluster do
586
586
  end
587
587
  module Module2
588
588
  end
589
- class_include_or_extend_prepends_includes( Module1, Module2 )
589
+ class_include_or_extend_prepends_includes( Module1, Module2 ).name = :some_name
590
590
  respond_to?( :append_features ).should == true
591
591
  module ModuleProof
592
592
  include ModuleCluster::Define::ClassCluster::Mock16
@@ -634,7 +634,7 @@ describe ModuleCluster::Define::ClassCluster do
634
634
  end
635
635
  module Module2
636
636
  end
637
- class_include_or_extend_prepends_extends( Module1, Module2 )
637
+ class_include_or_extend_prepends_extends( Module1, Module2 ).name = :some_name
638
638
  respond_to?( :extend_object ).should == true
639
639
  module ModuleProof
640
640
  include ModuleCluster::Define::ClassCluster::Mock17
@@ -688,7 +688,7 @@ describe ModuleCluster::Define::ClassCluster do
688
688
  end
689
689
  module Module2
690
690
  end
691
- class_include_or_extend_prepends_includes_and_extends( Module1, Module2 )
691
+ class_include_or_extend_prepends_includes_and_extends( Module1, Module2 ).name = :some_name
692
692
  respond_to?( :append_features ).should == true
693
693
  module ModuleProof
694
694
  include ModuleCluster::Define::ClassCluster::Mock18