dictum 0.0.7 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/README.md +1 -1
- data/lib/dictum.rb +1 -1
- data/lib/dictum/documenter.rb +1 -1
- data/lib/dictum/markdown_writer.rb +1 -1
- data/lib/dictum/version.rb +1 -1
- data/lib/tasks/default_configuration +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 5a10d8bee2da6e9f5443ca8141b6cffffa7bf5cf88f2a1211fc1f26aabeac110
|
4
|
+
data.tar.gz: e839452097d43648c93e4423f2ba5c3c632ccad1b30d5fdde175b26edd81814a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8cb36d9861e218a3250bbbf4a728b41dd45cd6782a99576a5c0d01297bcc26863f5e20fc680380c6e9017e1b142a2f4081e313ff45a5f00e344c6f98cd35dd56
|
7
|
+
data.tar.gz: 43aaa8596c32e6bce7ed5ad897cd2d407684385858897b1dfcf6a4c586fea2c513c8e933d4f64562bc61bb277f3de1e56ee095b08b62571b5be6fb33f984af95
|
data/README.md
CHANGED
@@ -45,7 +45,7 @@ describe V1::MyResourceController do
|
|
45
45
|
|
46
46
|
describe '#some_method' do
|
47
47
|
context 'some context for my resource' do
|
48
|
-
it 'returns status ok', dictum:
|
48
|
+
it 'returns status ok', dictum: 'This property exists to add a description to the endpoint. If you do not want a description, just set it to true' do
|
49
49
|
get :index
|
50
50
|
expect(response_status).to eq(200)
|
51
51
|
end
|
data/lib/dictum.rb
CHANGED
@@ -90,7 +90,7 @@ module Dictum
|
|
90
90
|
Dir.mkdir(@config[:output_path]) unless Dir.exist?(@config[:output_path])
|
91
91
|
Documenter.instance.reset_data
|
92
92
|
|
93
|
-
system "bundle exec rspec #{@config[:root_path]}" if @config[:test_suite] == :rspec
|
93
|
+
system "bundle exec rspec #{@config[:root_path]} --tag dictum" if @config[:test_suite] == :rspec
|
94
94
|
|
95
95
|
save_to_file
|
96
96
|
end
|
data/lib/dictum/documenter.rb
CHANGED
@@ -21,7 +21,7 @@ module Dictum
|
|
21
21
|
description = arguments[:description]
|
22
22
|
return if name.nil?
|
23
23
|
resources[name] ||= {}
|
24
|
-
resources[name][:description] = description if description
|
24
|
+
resources[name][:description] = description if description && description.is_a?(String)
|
25
25
|
resources[name][:endpoints] ||= []
|
26
26
|
update_temp
|
27
27
|
end
|
@@ -24,7 +24,7 @@ module Dictum
|
|
24
24
|
|
25
25
|
def write_index
|
26
26
|
output_file.puts "# #{@config[:index_title]}"
|
27
|
-
@temp_json['resources'].
|
27
|
+
@temp_json['resources'].each_key do |resource_name|
|
28
28
|
output_file.puts "- #{resource_name}"
|
29
29
|
end
|
30
30
|
output_file.puts "\n"
|
data/lib/dictum/version.rb
CHANGED
@@ -12,7 +12,7 @@ RSpec.configure do |config|
|
|
12
12
|
resource: test.metadata[:described_class].to_s.split('::').last.gsub('Controller', ''),
|
13
13
|
endpoint: request.fullpath,
|
14
14
|
http_verb: request.env['REQUEST_METHOD'],
|
15
|
-
description: test.metadata[:
|
15
|
+
description: test.metadata[:dictum],
|
16
16
|
request_headers: DEFAULT_REQUEST_HEADERS,
|
17
17
|
request_path_parameters: request.env['action_dispatch.request.path_parameters'].except(:controller, :action),
|
18
18
|
request_body_parameters: request.env['action_dispatch.request.parameters'].except('controller', 'action'),
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dictum
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alejandro Bezdjian
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-02-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: nokogiri
|
@@ -210,7 +210,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
210
210
|
version: '0'
|
211
211
|
requirements: []
|
212
212
|
rubyforge_project:
|
213
|
-
rubygems_version: 2.
|
213
|
+
rubygems_version: 2.7.3
|
214
214
|
signing_key:
|
215
215
|
specification_version: 4
|
216
216
|
summary: Document your APIs.
|