monkey-lib 0.5.3 → 0.5.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -17,8 +17,8 @@ module Monkey
17
17
  if klass
18
18
  @core_class = klass
19
19
  klass.send :include, self
20
- self::ClassMethods.extend ClassDsl
21
- self::ClassMethods.core_class @core_class
20
+ self::ExtClassMethods.extend ClassDsl
21
+ self::ExtClassMethods.core_class @core_class
22
22
  @core_class.class_eval <<-EOS
23
23
  def method_missing(meth, *args, &blk)
24
24
  return super if Monkey::Backend.setup?
@@ -52,7 +52,7 @@ module Monkey
52
52
  end
53
53
 
54
54
  def included(klass)
55
- klass.extend self::ClassMethods
55
+ klass.extend self::ExtClassMethods
56
56
  super
57
57
  end
58
58
 
@@ -78,7 +78,7 @@ module Monkey
78
78
  end
79
79
 
80
80
  def class_methods(&block)
81
- self::ClassMethods.class_eval(&block)
81
+ self::ExtClassMethods.class_eval(&block)
82
82
  end
83
83
 
84
84
  def expects(*list)
@@ -98,7 +98,7 @@ module Monkey
98
98
  class_name = filename.capitalize
99
99
  extension = eval <<-EOS
100
100
  module ::Monkey::Ext::#{class_name} # <- for MacRuby!?
101
- module ClassMethods; end # <- for 1.9
101
+ module ExtClassMethods; end # <- for 1.9
102
102
  self
103
103
  end
104
104
  EOS
@@ -1,7 +1,7 @@
1
1
  module Monkey
2
2
  module Ext
3
3
  module File
4
- module ClassMethods
4
+ module ExtClassMethods
5
5
  def write(path, content = '', mode = 'w')
6
6
  File.open(path, mode) { |f| f.write content }
7
7
  content
@@ -6,7 +6,7 @@ describe Monkey::Ext do
6
6
  before do
7
7
  @core_class = Class.new
8
8
  @extension = Module.new
9
- @extension::ClassMethods = Module.new
9
+ @extension::ExtClassMethods = Module.new
10
10
  @extension.extend Monkey::Ext::ExtDSL
11
11
  @extension.core_class @core_class
12
12
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: monkey-lib
3
3
  version: !ruby/object:Gem::Version
4
- hash: 13
4
+ hash: 3
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 5
9
- - 3
10
- version: 0.5.3
9
+ - 4
10
+ version: 0.5.4
11
11
  platform: ruby
12
12
  authors:
13
13
  - Konstantin Haase
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-09-07 00:00:00 +02:00
18
+ date: 2010-09-20 00:00:00 +02:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency