Releases: solana-foundation/surfpool-web-ui
Releases · solana-foundation/surfpool-web-ui
v0.1.0
chore: oss readiness (#25) * chore: give claude a pass at cleaning up repo (#23) * chore: give claude a pass at cleaning up repo * chore: remove subgraphs from docs/www * test: add tests (#22) * initial commit of vibe-coded tests * studio component unit tests * chore: export ConfigContext for test utilities Export the ConfigContext so test helpers can wrap components with pre-set config values without needing to mock fetch. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * chore: add shared test utilities (renderWithConfig, makeTx, makeConfig) Create test-utils.tsx with helpers for component testing: - renderWithConfig: wraps components in ConfigContext.Provider - makeTx: factory for TransactionInfo test data - makeConfig: factory for config objects Refactor solana-transaction-stream.test.ts to use shared makeTx. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * chore: add global clipboard mock to vitest setup Mock navigator.clipboard in jsdom so component tests involving copy buttons work without browser APIs. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * test: add component tests for TokenAmountDisplay and Stat TokenAmountDisplay: tests formatting, variants (default/compact/badge), showSymbol toggle, custom className, and large number grouping. Stat: tests title/value rendering and edge cases. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * test: add component tests for AddressDisplay Tests rendering, copy button visibility, clipboard interaction, explorer link with config-provided rpcUrl, empty/whitespace address fallbacks, copied state, and truncation. Uses renderWithConfig helper to provide ConfigContext. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * test: add integration test infrastructure - vitest.integration.config.ts: separate config for integration tests - integration-setup.ts: global setup that checks for running Surfpool - solana-websocket-service.integration.test.ts: RPC, config endpoint, and WebSocket connection/subscription tests against live Surfpool - Exclude *.integration.test.* from regular vitest run - Add test:integration script to package.json Integration tests require a running Surfpool instance and are only executed via `pnpm test:integration`. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * refactor: extract utility functions from TransactionInspector Move pure utility functions and TypeScript interfaces into transaction-inspector-utils.ts (~676 lines extracted): - Interfaces: AccountData, AccountChange, AccountState, etc. - Functions: getProgramType, getProgramName, decodeAccountData, mergeTransactionProfiles, processTransactionProfile, computeHexDiff, formatHexDump, formatHexOnly, getHexData, getHexDataForUpdates, hasJsonData, extractProgramData, findChangedPaths transaction-inspector.tsx reduced from 3,342 to 2,656 lines. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * refactor: extract display sub-components from TransactionInspector Move 10 display components into transaction-inspector-components.tsx: LamportsDisplay, OwnerDisplay, DataDisplay, LamportsComparison, PermissionsBox, AccountLabels, OwnerComparison, DataComparison, AccountDetails, UpdateAccountDetails. transaction-inspector.tsx reduced from 2,656 to 1,512 lines (55% reduction from original 3,342 lines). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * test: add tests for extracted TransactionInspector code transaction-inspector-utils.test.ts (53 tests): - getProgramType/Name, decodeAccountData, computeHexDiff - formatHexDump, formatHexOnly, getHexData, getHexDataForUpdates - hasJsonData, extractProgramData, findChangedPaths transaction-inspector-components.test.tsx (14 tests): - LamportsDisplay, LamportsComparison, PermissionsBox, AccountLabels Total: 171 tests across 12 files. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * chore: remove unused imports from TransactionInspector Remove 9 unused component/type imports and the unused TokenAmountDisplay import. These are internal to transaction-inspector-components.tsx and don't need to be re-imported into the main file. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * remove unused imports --------- Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * chore: split up scenarios bento and add tests (#24) * chore: clean up constants use * ci: add release ci on tag push --------- Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>