-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* put tests and static checks in individual workflow files * add common tasks for linting and cycle detection * move prettier setup to root * update prettier setup * fix format in repo * pull cspell config to the root * fix spelling issues * remove obsolete scripts * add missing scripts * split out e2e tests
- Loading branch information
1 parent
5a15a5d
commit d2730f9
Showing
161 changed files
with
615 additions
and
609 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
name: Static Checks | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
typecheck: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: pnpm/action-setup@v4 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: latest | ||
cache: 'pnpm' | ||
cache-dependency-path: '**/pnpm-lock.yaml' | ||
- run: pnpm install --prefer-offline | ||
- name: Typecheck | ||
run: pnpm check-types | ||
|
||
lint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: pnpm/action-setup@v4 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: latest | ||
cache: 'pnpm' | ||
cache-dependency-path: '**/pnpm-lock.yaml' | ||
- run: pnpm install --prefer-offline | ||
- name: Typecheck | ||
run: pnpm lint | ||
|
||
check-cycles: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: pnpm/action-setup@v4 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: latest | ||
cache: 'pnpm' | ||
cache-dependency-path: '**/pnpm-lock.yaml' | ||
- run: pnpm install --prefer-offline | ||
- name: Typecheck | ||
run: pnpm check-cycles | ||
|
||
check-format: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: pnpm/action-setup@v4 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: latest | ||
cache: 'pnpm' | ||
cache-dependency-path: '**/pnpm-lock.yaml' | ||
- run: pnpm install --prefer-offline | ||
- name: Typecheck | ||
run: pnpm check-format | ||
|
||
check-spelling: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: pnpm/action-setup@v4 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: latest | ||
cache: 'pnpm' | ||
cache-dependency-path: '**/pnpm-lock.yaml' | ||
- run: pnpm install --prefer-offline | ||
- name: Typecheck | ||
run: pnpm check-spelling |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: Tests | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
unit_tests: | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
working-directory: ./extension | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: pnpm/action-setup@v4 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: latest | ||
cache: 'pnpm' | ||
cache-dependency-path: '**/pnpm-lock.yaml' | ||
- run: pnpm install --prefer-offline | ||
- run: pnpm test:unit | ||
- name: 'Report Coverage' | ||
# Set if: always() to also generate the report if tests are failing | ||
# Only works if you set `reportOnFailure: true` in your vite config as specified above | ||
if: always() | ||
uses: davelosert/vitest-coverage-report-action@v2 | ||
with: | ||
working-directory: extension |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
playwright-report | ||
|
||
*.zip | ||
*.toml | ||
*.patch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
<!DOCTYPE html> | ||
<!doctype html> | ||
<head> | ||
<meta charset="utf-8" /> | ||
<meta | ||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,27 @@ | ||
import { createRequestHandler } from "@remix-run/express" | ||
import express from "express" | ||
import { createRequestHandler } from '@remix-run/express' | ||
import express from 'express' | ||
|
||
const viteDevServer = | ||
process.env.NODE_ENV === "production" | ||
process.env.NODE_ENV === 'production' | ||
? null | ||
: await import("vite").then((vite) => | ||
: await import('vite').then((vite) => | ||
vite.createServer({ | ||
server: { middlewareMode: true }, | ||
}) | ||
}), | ||
) | ||
|
||
const app = express() | ||
app.use( | ||
viteDevServer ? viteDevServer.middlewares : express.static("build/client") | ||
viteDevServer ? viteDevServer.middlewares : express.static('build/client'), | ||
) | ||
|
||
const build = viteDevServer | ||
? () => viteDevServer.ssrLoadModule("virtual:remix/server-build") | ||
: await import("./build/server/index.js") | ||
? () => viteDevServer.ssrLoadModule('virtual:remix/server-build') | ||
: await import('./build/server/index.js') | ||
|
||
// and your app is "just a request handler" | ||
app.all("*", createRequestHandler({ build })) | ||
app.all('*', createRequestHandler({ build })) | ||
|
||
app.listen(3030, () => { | ||
console.log("App listening on http://localhost:3030") | ||
console.log('App listening on http://localhost:3030') | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
import type { Config } from "tailwindcss"; | ||
import type { Config } from 'tailwindcss' | ||
|
||
export default { | ||
content: ["./app/**/*.tsx"], | ||
content: ['./app/**/*.tsx'], | ||
theme: { | ||
extend: {}, | ||
}, | ||
plugins: [], | ||
} satisfies Config; | ||
} satisfies Config |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.