Commit Graph
15 Commits
Author SHA1 Message Date
codingetandCodex 6499f202ad fix(tooling): typecheck support workspaces
CI / install (pull_request) Successful in 8m10s
CI / lint (pull_request) Successful in 3m7s
CI / format (pull_request) Successful in 3m8s
CI / typecheck (pull_request) Successful in 3m39s
CI / typetest (pull_request) Successful in 3m22s
CI / browser-tests (pull_request) Successful in 5m49s
CI / node-tests (pull_request) Successful in 1m22s
Co-Authored-By: gpt-5.6-sol <noreply@openai.com>
2026-08-20 17:12:54 +00:00
codinget f4131462af build(turbo): fix turbo cache with submodules
CI / format (pull_request) Successful in 2m39s
CI / lint (pull_request) Successful in 2m55s
CI / install (pull_request) Successful in 7m57s
CI / typetest (pull_request) Successful in 2m4s
CI / node-tests (pull_request) Successful in 2m40s
CI / typecheck (pull_request) Successful in 2m44s
CI / browser-tests (pull_request) Successful in 4m13s
2026-08-01 00:19:50 +00:00
codingetandCodex 2cabbf50f1 test: tighten package-boundary checks
CI / format (pull_request) Successful in 1m58s
CI / lint (pull_request) Successful in 2m0s
CI / install (pull_request) Successful in 5m26s
CI / typetest (pull_request) Successful in 1m27s
CI / node-tests (pull_request) Successful in 1m48s
CI / typecheck (pull_request) Successful in 1m49s
CI / browser-tests (pull_request) Successful in 3m10s
Co-Authored-By: gpt-5.6-sol <noreply@openai.com>
2026-07-26 15:50:36 +00:00
codingetandCodex 717eeb997a fix: close package-boundary lint gaps
Co-Authored-By: gpt-5.6-sol <noreply@openai.com>
2026-07-26 14:13:21 +00:00
codingetandCodex c39e5c2177 chore: declare supported Node and npm engines
CI / lint (pull_request) Successful in 1m1s
CI / format (pull_request) Successful in 1m6s
CI / install (pull_request) Successful in 4m9s
CI / typetest (pull_request) Successful in 1m11s
CI / node-tests (pull_request) Successful in 1m27s
CI / typecheck (pull_request) Successful in 1m28s
CI / browser-tests (pull_request) Successful in 2m41s
Co-Authored-By: gpt-5.6-sol <noreply@openai.com>
2026-07-25 17:43:08 +00:00
codinget a1081a8194 test: setup node tests in CI 2026-06-23 22:13:38 +00:00
codingetandClaude 673fa3aba3 fix(test): address code review feedback on browser testing PR
- serveDirectory: replace regex path traversal guard with resolve+relative
  check, which is simpler to reason about and handles encoded edge cases
- drop test:browser:coverage scripts; c8 only covers Node orchestration
  code, not browser-executed code inside page.evaluate() — the resulting
  lcov is nearly empty and would confuse CI coverage dashboards
- guard server?.close() in after() hooks so teardown doesn't throw a
  TypeError if the before() hook failed to start the server
- extract setupLoopback() helper inside each page.evaluate() in
  transport.browser.ts to avoid verbatim repetition between tests
- add comment in helpers.browser.ts explaining the IDB readonly-transaction
  trick that ensures setState()'s async write has settled before opening
  a second IndexedDBState instance

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-21 12:47:31 +00:00
codingetandClaude c89c478286 feat(test): add browser integration testing with Playwright
Uses Playwright as a library within node:test (not @playwright/test) to
keep the same runner and script conventions. Browser test files use the
*.browser.ts extension so the existing src/**/*.test.ts glob picks up zero
browser tests, leaving the regular test suite unaffected.

Key pieces:
- .npmrc: PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=1 prevents binary downloads on
  npm ci; browsers are installed explicitly in CI via playwright install
- @webnet/browser-test-utils: new private package exporting forBrowsers()
  (iterates chromium + firefox, handles browser lifecycle within node:test
  suite/before/after) and a serveDirectory() helper (minimal http.createServer
  that serves a built dist/ or out/ directory so the browser can fetch ES
  modules via dynamic import())
- test:browser / test:browser:coverage scripts added to transport, vfs,
  tsconnect following the same c8 + lcov pattern as test:coverage
- turbo.json: test:browser and test:browser:coverage tasks depend on build +
  ^build (dist/ must exist before the browser can import from it)
- .gitea/workflows/test-browser.yml: CI pipeline that installs browsers with
  --with-deps then runs npm run test:browser

Integration tests:
- DataChannelTransport: real RTCPeerConnection loopback (both peers in one
  page context), exercises send/receive and close propagation
- FsaVFS: OPFS round-trip (writeFile/readFile), stat, readdir, delete
- IndexedDBState: multi-instance persistence (write via instance 1, open
  fresh instance 2 and verify IDB round-trip), empty-DB initialisation
- FsaFileOps: write/read/stat/remove cycle and rename/listFiles over OPFS

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-21 12:47:30 +00:00
codinget 862a52ee0a chore: run scripts on everything we can 2026-06-06 22:35:51 +00:00
codingetandClaude ff48c40aae chore(turbo): add typecheck and typetest pipeline tasks
Same filter approach as test: scoped to transport/http/websocket to avoid
pulling in tsconnect via example-app's ^build chain. typetest is http-only.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-06 22:19:44 +00:00
codingetandClaude f5569263f4 chore(turbo): filter test pipeline to packages with tests
turbo run test was building the full workspace graph (including tsconnect,
which requires the tailscale submodule) because example-app and test-app
transitively pull it in via ^build. Scope test and test:coverage to the
three packages that actually have test scripts.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-06 22:03:30 +00:00
codingetandClaude c05f20c0bf chore: add test/test:coverage to turbo; remove unit/external test split
- turbo.json: add test and test:coverage pipeline tasks (dependsOn: ^build)
- root package.json: add test and test:coverage scripts via turbo
- Remove test:unit, test:coverage:unit, test:watch:unit from all packages
- Remove test-helpers/flags.ts from transport, http, websocket (and dirs)
- Remove fetch.node.test.ts (external test hitting google.com; always skipped)
- Drop { skip: skipIfNotIntegration } from all suites — tests run unconditionally

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-06 21:52:42 +00:00
codingetandClaude 0665ff0acd feat: add turborepo for dependency-aware parallel builds
Replaces `npm run build --workspaces --if-present` with `turbo run build`,
which resolves build order from each package's package.json dependencies
and parallelises independent packages automatically.

- turbo.json: declares build task with `^build` topological dependency
- package.json: switches build script to turbo, adds packageManager field
  (required by turbo v2), adds turbo to devDependencies
- .gitignore: add .turbo/ cache directory
- tailscale: bump submodule for tsconfig types-pinning fix

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-18 20:15:43 +00:00
codingetandClaude 341ece4f55 chore: add prettier, eslint, dpdm, lint-staged, commitlint; bump TS to 6
- Add Prettier with .prettierrc.json and format all source files
- Add ESLint v9 flat config with @eslint/js + typescript-eslint
- Add dpdm for circular dependency checking
- Add lint-staged (runs eslint + prettier on staged files)
- Add commitlint with conventional commits config
- Add husky pre-commit (lint-staged) and commit-msg (commitlint) hooks
- Bump TypeScript to ^6.0.2 in both packages
- Fix tsconnect moduleResolution: node → bundler (node10 deprecated in TS 6)
- Remove unused IPNConfig import and stale eslint-disable in ipn.ts

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-11 20:35:51 +00:00
codingetandClaude b60522507f feat: initialize npm monorepo with tsconnect wasm package
Set up npm workspaces monorepo with the tailscale/tailscale repo as a
git submodule. Adds packages/tsconnect which builds the tsconnect wasm
via tailscale's Go toolchain and compiles a TypeScript wrapper that
initializes the wasm, captures newIPN from the global scope, removes it
to avoid pollution, and re-exports it with proper module-scoped types.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-09 23:19:25 +00:00