diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 87ad477..a834ed4 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -56,7 +56,7 @@ Project maintainers are responsible for clarifying and enforcing our standards o ``` 3. **Add upstream remote**: ```bash - git remote add upstream https://github.com/ORIGINAL_OWNER/pacto-p2p.git + git remote add upstream https://github.com/PACTO-LAT/pacto-p2p.git ``` 4. **Install dependencies**: ```bash @@ -93,7 +93,7 @@ Examples: ### Making Changes -1. **Create a new branch** from `main`: +1. **Create a new branch** from `develop` (the default integration branch): ```bash git checkout -b feature/your-feature-name ``` @@ -116,7 +116,7 @@ Examples: 5. **Keep your branch updated**: ```bash git fetch upstream - git rebase upstream/main + git rebase upstream/develop ``` 6. **Push to your fork**: @@ -221,7 +221,7 @@ export function EscrowCard(props: any) { 1. **Automated checks**: All CI checks must pass 2. **Code review**: At least one maintainer must approve 3. **Address feedback**: Make requested changes and push updates -4. **Keep PR updated**: Rebase on `main` if conflicts arise +4. **Keep PR updated**: Rebase on `develop` if conflicts arise ### After Approval @@ -304,25 +304,7 @@ Fixes #456 ## ๐Ÿงช Testing -### Running Tests - -```bash -# Run all tests -npm test - -# Run tests in watch mode -npm test -- --watch - -# Run tests for specific package -npm test --workspace=@pacto-p2p/shared -``` - -### Writing Tests - -- Write tests for new features -- Ensure existing tests pass -- Aim for good test coverage -- Test edge cases and error scenarios +Automated test scripts are not wired up in the root `package.json` yet. Before opening a PR, run the quality checks listed in [Making Changes](#making-changes) (`type-check`, `biome:check`, `build`). When you add automated tests in a package, document the exact command in your PR description so reviewers can run them. ## ๐Ÿ“– Documentation diff --git a/apps/web/app/error.tsx b/apps/web/app/error.tsx new file mode 100644 index 0000000..fb42e04 --- /dev/null +++ b/apps/web/app/error.tsx @@ -0,0 +1,43 @@ +'use client'; + +import { AlertTriangle } from 'lucide-react'; +import Link from 'next/link'; +import { useEffect } from 'react'; +import { Button } from '@/components/ui/button'; + +export default function ErrorPage({ + error, + reset, +}: { + error: Error & { digest?: string }; + reset: () => void; +}) { + useEffect(() => { + console.error(error); + }, [error]); + + return ( +
+
+ +

+ Something went wrong +

+

+ {error.message || 'An unexpected error occurred. Please try again.'} +

+
+ + +
+
+
+ ); +} diff --git a/apps/web/app/not-found.tsx b/apps/web/app/not-found.tsx new file mode 100644 index 0000000..fec0248 --- /dev/null +++ b/apps/web/app/not-found.tsx @@ -0,0 +1,25 @@ +import { FileQuestion } from 'lucide-react'; +import Link from 'next/link'; +import { Button } from '@/components/ui/button'; + +export default function NotFoundPage() { + return ( +
+
+ +

+ Page not found +

+

+ The page you are looking for does not exist or may have been moved. +

+ +
+
+ ); +}