grape-raketasks 0.0.2 → 0.0.3
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 955e1636f66307dc8207155aa4e91fb677a3ee6e
|
4
|
+
data.tar.gz: 560a27a495c2d19efaaf5de0ebfef9f46bbc757c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7556454292f4b13f7384c0e08091f92d95f83d9362af44fe0e391e9ba81cf5813764ba6ed0f837e12e58810b0b5d1057cac4d04ea1dd349e267bfc8b1baa586c
|
7
|
+
data.tar.gz: 4fe27a7516bdf3b100d2ec8e2b778499ba13c6deaed05e54f9bf0d7111b9860f0a308eddfba46803b606fb0fac3e7819a33c358023c553ace5f829987c574e7b
|
@@ -22,9 +22,10 @@ module GrapeRakeTasks
|
|
22
22
|
end
|
23
23
|
|
24
24
|
def self.route_with_api_name(grape_route, api_name)
|
25
|
-
|
26
|
-
|
27
|
-
|
25
|
+
route = grape_route.dup
|
26
|
+
new_opts = route.options.merge(api: api_name)
|
27
|
+
route.options = new_opts
|
28
|
+
route
|
28
29
|
end
|
29
30
|
end
|
30
31
|
end
|
@@ -5,7 +5,9 @@ describe GrapeRakeTasks::ConsoleFormatter do
|
|
5
5
|
|
6
6
|
describe '#construct_output' do
|
7
7
|
before do
|
8
|
-
formatter
|
8
|
+
allow(formatter)
|
9
|
+
.to receive(:format_route)
|
10
|
+
.and_return('formatted route')
|
9
11
|
end
|
10
12
|
|
11
13
|
context 'when routes exist' do
|
@@ -16,7 +16,7 @@ describe GrapeRakeTasks::Route do
|
|
16
16
|
it 'returns a collection of routes that know their parent API' do
|
17
17
|
routes = described_class.api_routes(SampleApiOne::API)
|
18
18
|
every_route_has_api = routes.all? { |r| r.options.key?(:api) }
|
19
|
-
expect(every_route_has_api).to
|
19
|
+
expect(every_route_has_api).to eq(true)
|
20
20
|
end
|
21
21
|
end
|
22
22
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: grape-raketasks
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- H. Henn
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-09-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: grape
|
@@ -124,3 +124,4 @@ test_files:
|
|
124
124
|
- spec/grape-raketasks/route_spec.rb
|
125
125
|
- spec/spec_helper.rb
|
126
126
|
- spec/support/test_objects.rb
|
127
|
+
has_rdoc:
|