omoteura 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +20 -0
- data/README.md +27 -11
- metadata +20 -6
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 666f7a37974455a114aad72db4711311e3ca439e6caaec4059021892995343b2
|
|
4
|
+
data.tar.gz: 0a5dd61b7e1430f808fd31981bf6094614453dc0acecc1a4ba12546b9ee96934
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 8762cf7aca1530b115431533a7ef631f690b7186d4c261eaae99ef2551b14a04774df586e370509eab8977fc115e40651caf2839e4084f27db80aaa84659346b
|
|
7
|
+
data.tar.gz: 0bff7167d9ca5cb70060afa8d1c94588ee4f471bcd1f83032fac4109154b5c193621ae0d919060ed0a95cdbf39844a16b7c1ecdec5929c3e67565136f5081fd9
|
data/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,26 @@ project follows [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
|
6
6
|
|
|
7
7
|
## Unreleased
|
|
8
8
|
|
|
9
|
+
## 0.2.0 - 2026-10-23
|
|
10
|
+
|
|
11
|
+
Minitest support.
|
|
12
|
+
|
|
13
|
+
### Added
|
|
14
|
+
|
|
15
|
+
- Minitest tests are examples, like RSpec's: a test class is an example group
|
|
16
|
+
and its `test "…"` blocks and `test_…` methods are examples, so links can
|
|
17
|
+
name a test by its description, and drafts and the link picker list them.
|
|
18
|
+
- `omoteura-minitest`, a Minitest reporter that records test results like
|
|
19
|
+
the RSpec formatter, turned on by `require "omoteura/minitest"` in
|
|
20
|
+
`test/test_helper.rb`. The `omoteura` gem now installs it too.
|
|
21
|
+
- `omoteura coverage` also looks for a file's Minitest test, such as
|
|
22
|
+
`test/models/user_test.rb` for `app/models/user.rb`, beside its spec.
|
|
23
|
+
|
|
24
|
+
## 0.1.1 - 2026-10-23
|
|
25
|
+
|
|
26
|
+
No changes to the gems. Released with the same version as the VS Code
|
|
27
|
+
extension, which leaves out excalidraw.com's settings it never used.
|
|
28
|
+
|
|
9
29
|
## 0.1.0 - 2026-10-23
|
|
10
30
|
|
|
11
31
|
The first release.
|
data/README.md
CHANGED
|
@@ -11,7 +11,7 @@ Code in front, context behind.
|
|
|
11
11
|
|
|
12
12
|
The code is the *omote* (front). Behind it sits an Excalidraw drawing, the
|
|
13
13
|
*ura* (back): diagrams, notes and the reasons behind the code, with shapes
|
|
14
|
-
that link to the
|
|
14
|
+
that link to the tests and methods they describe.
|
|
15
15
|
|
|
16
16
|
> **Status:** pre-release, not yet on RubyGems. The gems below already resolve
|
|
17
17
|
> links, check them in CI and record test results. The VS Code extension in
|
|
@@ -55,7 +55,7 @@ as well as time. Files without a magic comment are skipped without allocating.
|
|
|
55
55
|
|
|
56
56
|
* Rails 7.1, 7.2, 8.0, 8.1 projects; Omoteura reads their files and never loads Rails
|
|
57
57
|
|
|
58
|
-
* RSpec 3.12+
|
|
58
|
+
* RSpec 3.12+ or Minitest 5.21+
|
|
59
59
|
|
|
60
60
|
* Excalidraw (`.excalidraw`) and Obsidian Excalidraw (`.excalidraw.md`)
|
|
61
61
|
|
|
@@ -71,7 +71,7 @@ end
|
|
|
71
71
|
```
|
|
72
72
|
|
|
73
73
|
`require: false` keeps Rails from loading Omoteura into your application; the
|
|
74
|
-
`omoteura` command and
|
|
74
|
+
`omoteura` command and your test framework load what they need. Then bundle:
|
|
75
75
|
|
|
76
76
|
```sh
|
|
77
77
|
% bundle
|
|
@@ -82,7 +82,8 @@ end
|
|
|
82
82
|
| gem | contents |
|
|
83
83
|
| --- | --- |
|
|
84
84
|
| `omoteura-core` | Diagram files, `omoteura:` links and the `omoteura` command |
|
|
85
|
-
| `omoteura-rspec` | A formatter that records
|
|
85
|
+
| `omoteura-rspec` | A formatter that records RSpec results for diagrams |
|
|
86
|
+
| `omoteura-minitest` | A reporter that records Minitest results for diagrams |
|
|
86
87
|
|
|
87
88
|
|
|
88
89
|
## Attaching Diagrams
|
|
@@ -188,19 +189,34 @@ Actions, add `--format github` to see the problems as annotations.
|
|
|
188
189
|
|
|
189
190
|
## Recording Test Results
|
|
190
191
|
|
|
191
|
-
|
|
192
|
+
With RSpec, add the formatter to `.rspec`, next to your usual one:
|
|
192
193
|
|
|
193
194
|
```text
|
|
194
195
|
--format progress
|
|
195
196
|
--format Omoteura::RSpec::Formatter --out tmp/omoteura/results.json
|
|
196
197
|
```
|
|
197
198
|
|
|
198
|
-
|
|
199
|
-
|
|
199
|
+
With Minitest, including Rails' `bin/rails test`, require the reporter in
|
|
200
|
+
`test/test_helper.rb`:
|
|
201
|
+
|
|
202
|
+
```ruby
|
|
203
|
+
require "omoteura/minitest"
|
|
204
|
+
```
|
|
205
|
+
|
|
206
|
+
Each test's status and failure message go to `tmp/omoteura/results.json`
|
|
207
|
+
(for Minitest, `OMOTEURA_RESULTS` names another path). Keep `tmp/omoteura/`
|
|
208
|
+
out of version control.
|
|
209
|
+
|
|
210
|
+
Minitest tests link like RSpec examples: in a test class such as
|
|
211
|
+
`UserTest < ActiveSupport::TestCase`, `test "requires an email"` is
|
|
212
|
+
`omoteura:#requires an email`, and `def test_display_name` is
|
|
213
|
+
`omoteura:#test_display_name`. The coverage panel looks for
|
|
214
|
+
`test/models/user_test.rb` as well as `spec/models/user_spec.rb`.
|
|
200
215
|
|
|
201
216
|
When something already measures coverage, as SimpleCov does, the formatter
|
|
202
|
-
also
|
|
203
|
-
which methods the tests called.
|
|
217
|
+
and the reporter also record which lines of your code ran, so the coverage
|
|
218
|
+
panel can tell which methods the tests called. They never start coverage
|
|
219
|
+
themselves.
|
|
204
220
|
|
|
205
221
|
|
|
206
222
|
## In VS Code
|
|
@@ -212,7 +228,7 @@ opens in Excalidraw with linked shapes outlined by test status; clicking a
|
|
|
212
228
|
link opens the code. Saving writes the file's own format, so an Obsidian note
|
|
213
229
|
keeps everything around the drawing, and a change made elsewhere since it
|
|
214
230
|
opened is never overwritten. A coverage panel lists which declarations and
|
|
215
|
-
public methods of the open file its
|
|
231
|
+
public methods of the open file its tests cover.
|
|
216
232
|
|
|
217
233
|
|
|
218
234
|
## Commands
|
|
@@ -224,7 +240,7 @@ public methods of the open file its specs cover.
|
|
|
224
240
|
| `omoteura inspect FILE` | Print one file's diagram, links and test results as JSON, for editors |
|
|
225
241
|
| `omoteura diagram FILE` | Print one diagram's drawing, links and test results as JSON, for editors |
|
|
226
242
|
| `omoteura links FILE` | Print the places in one code file a shape can link to, with their links, as JSON, for editors |
|
|
227
|
-
| `omoteura coverage FILE` | Print which declarations and public methods of one file its
|
|
243
|
+
| `omoteura coverage FILE` | Print which declarations and public methods of one file its tests cover, as JSON, for editors |
|
|
228
244
|
| `omoteura save FILE` | Save a drawing an editor changed, read as JSON from stdin, in the file's format |
|
|
229
245
|
| `omoteura version` | Print the version |
|
|
230
246
|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: omoteura
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.2.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- KAIBYAKU K.K
|
|
@@ -15,29 +15,43 @@ dependencies:
|
|
|
15
15
|
requirements:
|
|
16
16
|
- - '='
|
|
17
17
|
- !ruby/object:Gem::Version
|
|
18
|
-
version: 0.
|
|
18
|
+
version: 0.2.0
|
|
19
19
|
type: :runtime
|
|
20
20
|
prerelease: false
|
|
21
21
|
version_requirements: !ruby/object:Gem::Requirement
|
|
22
22
|
requirements:
|
|
23
23
|
- - '='
|
|
24
24
|
- !ruby/object:Gem::Version
|
|
25
|
-
version: 0.
|
|
25
|
+
version: 0.2.0
|
|
26
26
|
- !ruby/object:Gem::Dependency
|
|
27
27
|
name: omoteura-rspec
|
|
28
28
|
requirement: !ruby/object:Gem::Requirement
|
|
29
29
|
requirements:
|
|
30
30
|
- - '='
|
|
31
31
|
- !ruby/object:Gem::Version
|
|
32
|
-
version: 0.
|
|
32
|
+
version: 0.2.0
|
|
33
33
|
type: :runtime
|
|
34
34
|
prerelease: false
|
|
35
35
|
version_requirements: !ruby/object:Gem::Requirement
|
|
36
36
|
requirements:
|
|
37
37
|
- - '='
|
|
38
38
|
- !ruby/object:Gem::Version
|
|
39
|
-
version: 0.
|
|
40
|
-
|
|
39
|
+
version: 0.2.0
|
|
40
|
+
- !ruby/object:Gem::Dependency
|
|
41
|
+
name: omoteura-minitest
|
|
42
|
+
requirement: !ruby/object:Gem::Requirement
|
|
43
|
+
requirements:
|
|
44
|
+
- - '='
|
|
45
|
+
- !ruby/object:Gem::Version
|
|
46
|
+
version: 0.2.0
|
|
47
|
+
type: :runtime
|
|
48
|
+
prerelease: false
|
|
49
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
50
|
+
requirements:
|
|
51
|
+
- - '='
|
|
52
|
+
- !ruby/object:Gem::Version
|
|
53
|
+
version: 0.2.0
|
|
54
|
+
description: Meta gem that installs omoteura-core, omoteura-rspec and omoteura-minitest.
|
|
41
55
|
executables: []
|
|
42
56
|
extensions: []
|
|
43
57
|
extra_rdoc_files: []
|