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

yitsushi / totp-cli / 25945607496
56%
master: 20%

Build:
Build:
LAST BUILD BRANCH: main
DEFAULT BRANCH: master
Ran 15 May 2026 11:06PM UTC
Jobs 1
Files 28
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

15 May 2026 11:06PM UTC coverage: 55.519% (+28.2%) from 27.337%
25945607496

push

github

web-flow
fix: address potential bugs found in code review (#150)

* fix: address potential bugs found in code review

Bug fixes:
- import: pass empty namespace to AddNamespace so accounts from new
  namespaces are not mistakenly treated as conflicts, causing spurious
  overwrite prompts
- set-length: validate ParseUint result and re-prompt on non-numeric
  input instead of silently storing length=0
- cmd: propagate terminal read errors from all askFor* helpers to
  prevent infinite loops on EOF/pipe close (add_token, set_length,
  set_prefix, rename, instant)
- generateCode: return error instead of printing to stdout so callers
  can surface failures rather than displaying an empty token
- CheckPasswordConfirm: use crypto/subtle.ConstantTimeCompare to avoid
  timing side-channel

Refactoring for testability:
- terminal: extract Terminal interface; New() returns *ConcreteTerminal
- storage: add PasswordProvider interface + StaticPasswordProvider;
  FileBackend accepts provider via WithPasswordProvider option
- cmd: extract execute*/askFor* functions with injected Terminal and
  Storage dependencies; add prepareStorage helper

Linter:
- replace deprecated wsl with wsl_v5, gomodguard with gomodguard_v2
- fix all noinlineerr and wsl_v5 violations; update quality-check action

Tests (overall coverage 22% → 63%):
- internal/cmd: add_token, change_password, delete, dump, error types,
  generate, import, list, rename, set_length, set_prefix, update
- internal/security/algo: SHA1/SHA256/SHA512/Default Hasher (0% → 100%)
- internal/security: OTPError.Error (97% → 100%)
- internal/storage: error types, SetPassword, acquirePassword branches

Signed-off-by: Victoria Nadasdi <victoria@efertone.me>

* fix(storage): update expected error message for age v1.3.1

The filippo.io/age library changed its wrong-password error message in
v1.3.1; update the TestInvalidPassword assertion to match.

Signed-off-by: Victoria Nadasdi <victoria@efertone.me>

* chore(deps): bump dependencie... (continued)

286 of 430 new or added lines in 20 files covered. (66.51%)

4 existing lines in 3 files now uncovered.

674 of 1214 relevant lines covered (55.52%)

4.11 hits per line

Uncovered Changes

Lines Coverage ∆ File
20
49.07
49.07% internal/cmd/rename.go
19
34.92
34.92% internal/cmd/generate.go
14
39.13
39.13% internal/cmd/import.go
11
0.0
0.0% internal/cmd/instant.go
11
34.38
34.38% internal/cmd/update.go
10
50.0
50.0% internal/cmd/add_token.go
10
53.49
53.49% internal/cmd/delete.go
9
60.0
60.0% internal/cmd/set_length.go
9
54.84
54.84% internal/cmd/set_prefix.go
8
24.24
24.24% internal/cmd/dump.go
8
0.0
internal/cmd/helpers.go
6
50.0
50.0% internal/cmd/change_password.go
6
54.84
54.84% internal/cmd/list.go
2
0.0
0.0% internal/cmd/flags.go
1
68.1
4.67% internal/storage/filebackend.go

Coverage Regressions

Lines Coverage ∆ File
2
39.13
39.13% internal/cmd/import.go
1
50.0
50.0% internal/cmd/add_token.go
1
60.0
60.0% internal/cmd/set_length.go
Jobs
ID Job ID Ran Files Coverage
1 25945607496.1 15 May 2026 11:06PM UTC 28
55.52
GitHub Action Run
Source Files on build 25945607496
  • Tree
  • List 28
  • Changed 24
  • Source Changed 18
  • Coverage Changed 22
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #25945607496
  • d75bd36f on github
  • Prev Build on main (#17133562080)
  • Next Build on main (#25945618030)
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