• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

xu-chris / toon_ex / c762e615afe92857f8aa856472d1eaf494c1d634
68%

Build:
DEFAULT BRANCH: main
Ran 21 Jan 2026 06:57AM UTC
Jobs 1
Files 19
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

21 Jan 2026 06:56AM UTC coverage: 63.791% (+8.8%) from 54.957%
c762e615afe92857f8aa856472d1eaf494c1d634

push

github

web-flow
refactor: improve code quality and test coverage (#10)

Encoder refactoring:
- Refactor arrays.ex with pattern-matched clauses for composability
- Refactor objects.ex with pattern-matched encode_regular_entry/encode_folded_value
- Rename predicates to follow Elixir conventions (tabular_array?, list_array?)
- Extract reusable helpers (apply_marker, build_*_line functions)

Decoder refactoring:
- Remove Process dictionary anti-pattern from structural_parser.ex
- Thread metadata explicitly through all parsing functions
- Add key_was_quoted? and add_key_to_metadata helpers
- Clean up parser.ex by removing Process.put/get calls

Test improvements:
- Add decode/options_test.exs with 23 tests (100% coverage)
- Add encode/options_test.exs with 25 tests (100% coverage)
- Expand encoder_test.exs from 4 to 23 tests (65% coverage)
- Add test fixtures: UserWithOnly, StructWithoutEncoder
- Strengthen assertions with specific error.value checks

Total: 511 tests, 83.5% coverage, all quality checks pass.

Co-authored-by: Chris Xu <git@chrisxu.me>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>

248 of 418 new or added lines in 6 files covered. (59.33%)

8 existing lines in 4 files now uncovered.

673 of 1055 relevant lines covered (63.79%)

18.13 hits per line

Uncovered Changes

Lines Coverage ∆ File
90
58.46
3.36% lib/toon/decode/structural_parser.ex
60
34.11
1.26% lib/toon/encode/arrays.ex
12
85.42
9.81% lib/toon/encode/objects.ex
4
82.69
28.15% lib/toon/decode/decode.ex
3
72.73
-10.61% lib/toon/decode/parser.ex
1
78.26
-0.5% lib/toon/encode/encode.ex

Coverage Regressions

Lines Coverage ∆ File
4
58.46
3.36% lib/toon/decode/structural_parser.ex
2
85.42
9.81% lib/toon/encode/objects.ex
1
34.11
1.26% lib/toon/encode/arrays.ex
1
81.4
-2.33% lib/toon/shared/utils.ex
Jobs
ID Job ID Ran Files Coverage
1 c762e615afe92857f8aa856472d1eaf494c1d634.1 21 Jan 2026 06:57AM UTC 19
63.79
GitHub Action Run
Source Files on build c762e615afe92857f8aa856472d1eaf494c1d634
  • Tree
  • List 19
  • Changed 13
  • Source Changed 0
  • Coverage Changed 13
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • c762e615 on github
  • Prev Build on main (#F8B130EC...)
  • Next Build on main (#0D6DFA77...)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc