netatalk-config 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -8,7 +8,11 @@ module NetatalkConfig
8
8
  end
9
9
 
10
10
  def shares
11
- @shares ||= {}
11
+ @shares || clear
12
+ end
13
+
14
+ def clear
15
+ @shares = {}
12
16
  end
13
17
 
14
18
  private
@@ -1,3 +1,3 @@
1
1
  module NetatalkConfig
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
@@ -2,6 +2,8 @@ require "spec_helper"
2
2
  require "netatalk-config"
3
3
 
4
4
  describe NetatalkConfig do
5
+ before { NetatalkConfig.clear }
6
+
5
7
  context 'no shares' do
6
8
  its('afp') { should match(/\A\s*\z/) }
7
9
  end
@@ -38,5 +40,5 @@ describe NetatalkConfig do
38
40
  include_context 'advanced share'
39
41
  its('afp') { should include("[simple]\n path = /simple/path") }
40
42
  its('afp') { should include("[advanced]\n path = /advanced/path\n time machine = yes") }
41
- end
43
+ end
42
44
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: netatalk-config
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: