test: юнит-тесты на форматирование и разбивки крипто-портфеля + версия 1.1.6

Vitest для чистой логики: lib/format.ts (заодно поймал баг в
trimTrailingZeros на "-0.000") и расчёт разбивки по риску/монете/сети
на вкладке Crypto — вынес их из компонентов в отдельные тестируемые
функции. Тесты подключены в CI. Версия приложения обновлена до 1.1.6.
This commit is contained in:
ZProger
2026-09-09 00:52:27 +03:00
parent c3047c6d6a
commit f5c6591310
13 changed files with 1279 additions and 39 deletions

View File

@@ -64,3 +64,8 @@ jobs:
# and a type error a PR might introduce, same as `npm run build`
# locally before shipping a change.
- run: npm run build
# Vitest over the pure-logic modules (lib/format.ts, the Crypto tab's
# allocation math) — kept in the same job rather than a new one so a
# renamed job doesn't silently stop matching branch protection's
# required status checks.
- run: npm run test