mvcli 0.0.11 → 0.0.12

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f3899bbf5f7652090fcc016d3f09850b2012745a
4
- data.tar.gz: ae467b67ff7b3f4a3c3a452b1173d4a6bb37fbd5
3
+ metadata.gz: d6824dd7970a2422da62ebac790697827af7493b
4
+ data.tar.gz: e7e26c779892ddbc361db8e69d78e4c88f3a2c5f
5
5
  SHA512:
6
- metadata.gz: cc657dac474ae27bdaf9145da35b8355b03be14896424fd1b3eefcb1548780b6ef72057f31ad9cc8957d521eb590dd12dee70c41c1136346d8fd9346ae7165cd
7
- data.tar.gz: fd93d3d430ecdb9c386ffa76a7fce15276ea81c62bae0548a558164761d8c04433dc62be293171a2e35d2f765e4a747f05ee8a5170805feb836811b8b92f52b8
6
+ metadata.gz: 74431de1c5cb00bc2f51d87a10fe407696b8449a1071a28f16039f8ece375ec05ab360eee2a49e819b9b40f1c26fb7af0ebfc9a9a54c7af025c5a436bc45d705
7
+ data.tar.gz: 82af2de453863e0f74871bb61a83db8305e5a0bb638c805e2443c42dbca506399a53e2ec9bb80f428af8dc9b0e85358f3b1c14e16f851c23f3e04239b514021e
data/lib/mvcli/actions.rb CHANGED
@@ -12,6 +12,7 @@ module MVCLI
12
12
  end
13
13
 
14
14
  def [](key)
15
+ return key if key.respond_to?(:call)
15
16
  controller, method = key.split('#')
16
17
  Action.new @loader, @renderer, controller, method
17
18
  end
data/lib/mvcli/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module MVCLI
2
- VERSION = "0.0.11"
2
+ VERSION = "0.0.12"
3
3
  end
@@ -26,4 +26,9 @@ describe "MVCLI::Actions" do
26
26
  Then {controller.should have_received(:bar)}
27
27
  And {renderer.should have_received(:render).with(output, 'foo/bar', 'the context')}
28
28
  end
29
+
30
+ context "when the action is callable" do
31
+ Given(:app) { ->(c) {} }
32
+ Then { actions[app] == app }
33
+ end
29
34
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mvcli
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.11
4
+ version: 0.0.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Charles Lowell