Framework Support
Oorty automatically detects and configures testing for your framework.
Supported Frameworks
Oorty provides first-class support for the most popular React frameworks and meta-frameworks.
Next.js
RecommendedFull-stack React framework
- App Router & Pages Router
- Server Components testing
- API routes testing
- Middleware testing
Vite + React
SupportedLightning fast dev server
- React 18+ support
- TypeScript first
- Fast HMR testing
- Plugin ecosystem
Remix
SupportedFull stack web framework
- Loader/action testing
- Route testing
- Session testing
- Form testing
Astro
SupportedContent-focused framework
- React islands testing
- Static site testing
- API endpoint testing
- Content collection testing
Framework Detection
When you run npx oorty@latest init, Oorty automatically detects your framework by analyzing your project structure:
Next.js is detected by the presence of next.config.js or the next dependency.
- page.tsx
- layout.tsx
- utils.test.ts
- button.test.tsx
- home.spec.ts
- next.config.js
- oorty.json
- vitest.config.ts
- playwright.config.ts
Framework-Specific Configuration
Each framework has optimized default configurations. Here's what gets generated:
Next.js Vitest Config
vitest.config.ts
import { defineConfig } from 'vitest/config'import react from '@vitejs/plugin-react'import tsconfigPaths from 'vite-tsconfig-paths'export default defineConfig({ plugins: [react(), tsconfigPaths()], test: { environment: 'jsdom', globals: true, setupFiles: ['./__tests__/setup.ts'], include: ['__tests__/**/*.{test,spec}.{ts,tsx}'], exclude: ['e2e/**/*', 'node_modules/**/*'], coverage: { provider: 'v8', reporter: ['text', 'json', 'html'], exclude: [ 'node_modules/', '.next/', 'e2e/', ], }, },})Next.js Playwright Config
playwright.config.ts
import { defineConfig, devices } from '@playwright/test'export default defineConfig({ testDir: './e2e', fullyParallel: true, forbidOnly: !!process.env.CI, retries: process.env.CI ? 2 : 0, workers: process.env.CI ? 1 : undefined, reporter: 'html', use: { baseURL: 'http://localhost:3000', trace: 'on-first-retry', }, projects: [ { name: 'chromium', use: { ...devices['Desktop Chrome'] }, }, ], webServer: { command: 'npm run dev', url: 'http://localhost:3000', reuseExistingServer: !process.env.CI, },})Need a different framework?
Oorty is designed to be extensible. If your framework isn't listed, you can still use Oorty by manually specifying the framework in the configuration or by opening an issue on GitHub for first-class support.