automaildoc 0.1.0 → 0.1.1

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: 6e2aee9768896ee327fc454752fc826e7121ca4c
4
- data.tar.gz: 1607512fc35ea229cc242a3fa143dd2b9ed56b92
3
+ metadata.gz: 7dcf5243373c83e1fb94b1498d2b665c431271c4
4
+ data.tar.gz: 58d0b68aa9b9346ab6568e2699a60abd143771fb
5
5
  SHA512:
6
- metadata.gz: fb80f8fd9d306dadde60b47a0b6d22fee6229e8bae4b61b0bebc530bba6ec844675916592a4cc0a0d16f83edfbf595c2144143bcb6a7ef32681214e6ba3b2a30
7
- data.tar.gz: b2a4e6073171cb5a480af43a0002be58ed800a69be92fb142e380c61d6a61caf71df5feda5838ee61109572e04d646bc438fd4dc97e5c8889636f0486bc1e095
6
+ metadata.gz: d173fcc0cd49abf00ae5eab30e854d84419d32c9daff30efff2ea569d4924d9fe497f6a42206c04b68409547117227ed107d345a95c03667e486df5f372077e3
7
+ data.tar.gz: 95e185fc0374c3d78f168577e84fe282a3565f9ece1629008c8e733647b0ba97ac76d9f249270df7c70a659f61ec646b89b6a645027331fc0514e494527ca09f
@@ -1,5 +1,12 @@
1
1
  ## Change Log
2
2
 
3
+ ### 0.1.1
4
+
5
+ #### Improvements
6
+
7
+ - Custom description is available now.
8
+ - Table of content shows not each subject but each mail's description.
9
+
3
10
  ### 0.1.0
4
11
 
5
12
  - First release
data/README.md CHANGED
@@ -1,5 +1,6 @@
1
1
  # Automaildoc
2
2
 
3
+ [![Gem Version](https://badge.fury.io/rb/automaildoc.svg)](https://badge.fury.io/rb/automaildoc)
3
4
  [![Build Status](https://travis-ci.org/ohbarye/automaildoc.svg?branch=master)](https://travis-ci.org/ohbarye/automaildoc)
4
5
 
5
6
  Automaildoc is a gem to generate a list of about mails from your mail spec.
@@ -57,6 +58,18 @@ That's it. Then Automaildoc generates an HTML file to `./doc/mails`. The file sh
57
58
 
58
59
  You can see `spec/dummy/doc/toc.html` in this repository, which is auto-generated one from mail specs in `spec/mails`.
59
60
 
61
+ ### Custom description
62
+
63
+ You can write descriptions with let(:description).
64
+
65
+ ```ruby
66
+ describe 'Sign up mail', automaildoc: true do
67
+ let(:description) { 'Sign up mail for newly signed up user' }
68
+
69
+ # examples follow
70
+ end
71
+ ```
72
+
60
73
  ### Configuration
61
74
 
62
75
  - path - [String] location to put files (default: `./doc/mails`)
@@ -16,7 +16,11 @@ module Automaildoc
16
16
  end
17
17
 
18
18
  def description
19
- @example.full_description
19
+ if @context.respond_to?(:description)
20
+ @context.description.strip
21
+ else
22
+ @example.full_description
23
+ end
20
24
  end
21
25
 
22
26
  def mail
@@ -92,7 +92,7 @@
92
92
  <ul>
93
93
  <% @mails.each do |mail| %>
94
94
  <li>
95
- <a href="#<%= mail.id %>"><%= mail.subject %></a>
95
+ <a href="#<%= mail.id %>"><%= mail.description %></a>
96
96
  </li>
97
97
  <% end %>
98
98
  </ul>
@@ -1,3 +1,3 @@
1
1
  module Automaildoc
2
- VERSION = "0.1.0"
2
+ VERSION = "0.1.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: automaildoc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Masato Ohba
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-09-02 00:00:00.000000000 Z
11
+ date: 2017-09-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec