Skip to content

Fix sub-minute countdown display, add hook test coverage, fix Lighthouse env var - #322

Closed
yosemite01 wants to merge 1 commit into
FlowwStar:mainfrom
yosemite01:fix/issues-291-295-302-303
Closed

yosemite01 wants to merge 1 commit into
FlowwStar:mainfrom
yosemite01:fix/issues-291-295-302-303

Conversation

@yosemite01

Copy link
Copy Markdown
Contributor

Closes #291
Closes #295
Closes #302
Closes #303

#291 — sub-minute countdown showing "0m 45s"

formatTimeRemaining in lib/stream-utils.ts now only emits the minutes segment when minutes > 0 or a larger unit (hours) is already present, matching the existing pattern used for the days check. Sub-minute countdowns now read 45s instead of 0m 45s.

#295 — hook test coverage

Added unit tests under __tests__/hooks/ for the previously untested hooks: use-wallet, use-webhooks, use-token-price (+ usePortfolioValue/formatUsd), use-activity-feed, use-form-draft (+ clearExpiredDrafts), use-stream-history, use-show-usd, useBulkActions, useBulkSelect, and useNotifications, following the mocking conventions already used in use-contract.test.ts / use-streams.test.ts. (use-contract, use-auto-withdraw, and use-notifications already had coverage.)

#302 — e2e Playwright tests never run in CI

Verified this is already resolved on main (see .github/workflows/ci.yml's e2e job, added in 0adc415) — it installs Playwright browsers and runs npx playwright test on every push/PR to main. Closing as already addressed.

#303 — Lighthouse CI env var

.github/workflows/lighthouse.yml already set NEXT_PUBLIC_STREAM_CONTRACT_ID_TESTNET (matching lib/stellar.ts's default testnet read path), but was missing the _MAINNET counterpart. Added NEXT_PUBLIC_STREAM_CONTRACT_ID_MAINNET to the build step's env so both network variants are covered.

… var

- lib/stream-utils.ts: only render the minutes segment in
  formatTimeRemaining when minutes>0 or a larger unit is present, so
  sub-minute durations show "45s" instead of "0m 45s" (#291)
- __tests__/hooks/: add unit tests for previously untested hooks
  (use-wallet, use-webhooks, use-token-price, use-activity-feed,
  use-form-draft, use-stream-history, use-show-usd, useBulkActions,
  useBulkSelect, useNotifications) (#295)
- .github/workflows/lighthouse.yml: also pass
  NEXT_PUBLIC_STREAM_CONTRACT_ID_MAINNET at build time alongside the
  existing _TESTNET var, matching what lib/stellar.ts reads (#303)

Closes #291
Closes #295
Closes #303
@yosemite01

Copy link
Copy Markdown
Contributor Author

Superseded by #323, opened from the correct account.

@yosemite01 yosemite01 closed this Jul 24, 2026

This branch had an error being deployed

1 failed deployment
staging — 0cd949fb Deployed Jul 24, 2026 by christabel888 via deploy-staging #68
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

3 participants