rb_reloader 0.0.1 → 0.0.2

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.
@@ -6,7 +6,7 @@ module RbReloader
6
6
  @map ||= {}
7
7
 
8
8
  def self.new(file)
9
- @map[file] ||= super
9
+ @map[file] ||= super
10
10
  end
11
11
 
12
12
  class << self
@@ -57,5 +57,11 @@ module RbReloader
57
57
  def reload
58
58
  FileWatcher.each {|x| x.reload}
59
59
  end
60
+
61
+ def registered_rb
62
+ files = []
63
+ FileWatcher.each {|x| files << x.file }
64
+ files
65
+ end
60
66
  end
61
67
  end
@@ -1,3 +1,3 @@
1
1
  module RbReloader
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
@@ -37,6 +37,13 @@ describe RbReloader do
37
37
  change_back_test4
38
38
 
39
39
  end
40
+
41
+ it "should has registered 4 files" do
42
+ current_folder = File.expand_path("..", __FILE__)
43
+ RbReloader.register(["#{current_folder}/**/t*.rb"])
44
+
45
+ RbReloader.registered_rb.size.should == 4
46
+ end
40
47
  end
41
48
 
42
49
  def change_test1
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rb_reloader
3
3
  version: !ruby/object:Gem::Version
4
- hash: 29
4
+ hash: 27
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 1
10
- version: 0.0.1
9
+ - 2
10
+ version: 0.0.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - arkxu