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

type-ruby / t-ruby / 20479786397
76%

Build:
DEFAULT BRANCH: main
Ran 24 Dec 2025 06:15AM UTC
Jobs 1
Files 34
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

24 Dec 2025 06:14AM UTC coverage: 76.005% (+0.1%) from 75.882%
20479786397

push

github

web-flow
feat: integrate type checker into compiler for return type validation (#15)

* feat: integrate type checker into compiler for return type validation

Add `type_check` option to Compiler that validates return types
at compile time. When enabled, the compiler infers method return
types using ASTTypeInferrer and compares them against declared
return type annotations. Raises TypeCheckError on mismatch.

Changes:
- Add type_check parameter to Compiler.new
- Integrate ASTTypeInferrer for return type inference
- Validate both top-level functions and class methods
- Support union types, nullable types, and subtype relationships
- Fix TypeCheckError to properly inherit from StandardError

Fixes #14

* feat: enable type checking by default via Config

- Add type_check: true to DEFAULT_CONFIG in Config class
- Add Config#type_check? method to read the setting
- Compiler reads type_check? from config instead of parameter
- Remove redundant type_check parameter from Compiler.new
- CLI and Watcher use config-driven type checking
- Add type_check? mock to tests not testing type validation

* fix: normalize Boolean/bool types and disable type check in e2e

- Normalize Boolean, TrueClass, FalseClass to bool in type comparison
- Disable type checking in E2E integration test (tests compilation, not types)

63 of 69 new or added lines in 4 files covered. (91.3%)

5084 of 6689 relevant lines covered (76.01%)

1165.9 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
2
71.43
-1.3% lib/t_ruby/cli.rb
4
80.54
3.09% lib/t_ruby/compiler.rb
Jobs
ID Job ID Ran Files Coverage
1 20479786397.1 24 Dec 2025 06:15AM UTC 34
76.01
GitHub Action Run
Source Files on build 20479786397
  • Tree
  • List 34
  • Changed 4
  • Source Changed 4
  • Coverage Changed 4
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #20479786397
  • a2be080e on github
  • Prev Build on main (#20478251574)
  • Next Build on main (#20479867849)
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

© 2025 Coveralls, Inc