mirror of
https://github.com/coder/coder.git
synced 2025-07-09 11:45:56 +00:00
This just implements a basic sign-in flow, using the new endpoints in #29 :  This brings over several dependencies that are necessary: - `formik` - `yep` Ports over some v1 code to bootstrap it: - `FormTextField` - `PasswordField` - `CoderIcon` And implements basic sign-in: Fixes #37 Fixes #43 This does not implement it navbar integration (importantly - there is no way to sign out yet, unless you manually delete your `session_token`). I'll do that in the next PR - figured this was big enough to get reviewed.
37 lines
1.1 KiB
JavaScript
37 lines
1.1 KiB
JavaScript
module.exports = {
|
|
projects: [
|
|
{
|
|
coverageReporters: ["text", "lcov"],
|
|
displayName: "test",
|
|
preset: "ts-jest",
|
|
roots: ["<rootDir>/site"],
|
|
setupFilesAfterEnv: ["<rootDir>/_jest/setupTests.ts"],
|
|
transform: {
|
|
"^.+\\.tsx?$": "ts-jest",
|
|
},
|
|
testEnvironment: "jsdom",
|
|
testRegex: "(/__tests__/.*|(\\.|/)(test|spec))\\.tsx?$",
|
|
testPathIgnorePatterns: ["/node_modules/", "/__tests__/fakes"],
|
|
moduleDirectories: ["node_modules", "<rootDir>"],
|
|
},
|
|
{
|
|
displayName: "lint",
|
|
runner: "jest-runner-eslint",
|
|
testMatch: ["<rootDir>/site/**/*.js", "<rootDir>/site/**/*.ts", "<rootDir>/site/**/*.tsx"],
|
|
testPathIgnorePatterns: ["/.next/", "/out/"],
|
|
},
|
|
],
|
|
collectCoverageFrom: [
|
|
"<rootDir>/site/**/*.js",
|
|
"<rootDir>/site/**/*.ts",
|
|
"<rootDir>/site/**/*.tsx",
|
|
"!<rootDir>/site/**/*.stories.tsx",
|
|
"!<rootDir>/site/.next/**/*.*",
|
|
"!<rootDir>/site/api.ts",
|
|
"!<rootDir>/site/dev.ts",
|
|
"!<rootDir>/site/next-env.d.ts",
|
|
"!<rootDir>/site/next.config.js",
|
|
"!<rootDir>/site/out/**/*.*",
|
|
],
|
|
}
|