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

valkyrjaio / sindri-ts / 30611796011
100%

Build:
DEFAULT BRANCH: 26.x
Ran 31 Jul 2026 07:08AM UTC
Jobs 1
Files 46
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

31 Jul 2026 07:07AM UTC coverage: 100.0%. Remained the same
30611796011

push

github

web-flow
[Generate] refactor: Extract the specifier helpers into a shared base (#86)

# Description

Moves the import-specifier helpers out of `GenerateDataFromAst` into a
shared base, so more than one
generate command can use them.

A generated file sits in a different directory from the files it
references, so every command that writes
TypeScript must turn an absolute path into the specifier that file
should import it by. Application source
takes a path relative to the output directory. A file inside an
installed package takes that package's own
public specifier, read by inverting the package's `exports` map. Today
`GenerateDataFromAst` owns that logic
and is the only class that can use it.

This is a pure move. No method body changes. `GenerateDataFromAst` now
extends the new base and calls
`super()`, and every existing test continues to exercise the moved
methods through it.

The next change adds a second generate command that needs the same
behavior. Without this move that command
would either duplicate the logic or reach into a class it has nothing
else to do with.

## Types of changes

- [x] Improvement _(non-breaking change which improves code)_
- [ ] Bug fix _(non-breaking change which fixes an issue)_
- [ ] New feature _(non-breaking change which adds functionality)_
- [ ] Deprecation _(breaking change which removes functionality)_
- [ ] Breaking change _(fix or feature that would cause existing
functionality to change)_
- [ ] Documentation improvement

## Changes

- **`src/Sindri/Generate/Abstract/GenerateFromAst.ts`** — new abstract
base holding `relativeSpecifier`,
`importSpecifier`, `packageSpecifier`, `exportedSubpath`,
`readPackageExports`, and `firstStringTarget`,
  moved unchanged.
- **`src/Sindri/Generate/Abstract/GenerateDataFromAst.ts`** — extends
the new base, and its constructor now
  calls `super()`. The six methods are gone from this file.

Full gate green: `tsc --noEmit`, ESLint, Prettier, and every test at
100% line and branch covera... (continued)

834 of 834 branches covered (100.0%)

Branch coverage included in aggregate %.

53 of 53 new or added lines in 2 files covered. (100.0%)

1334 of 1334 relevant lines covered (100.0%)

12.79 hits per line

Jobs
ID Job ID Ran Files Coverage
1 30611796011.1 31 Jul 2026 07:08AM UTC 46
100.0
GitHub Action Run
Source Files on build 30611796011
  • Tree
  • List 46
  • Changed 1
  • Source Changed 1
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #30611796011
  • 6639d4ed on github
  • Prev Build on 26.x (#30517329137)
  • Next Build on 26.x (#30612251087)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc