Skip to content

Conversation

@BadPirate
Copy link
Owner

Improve testing, add playwright, fix issue with account creation.

@BadPirate BadPirate requested a review from Copilot April 25, 2025 19:41
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR improves the overall quality of the application by enhancing testing, adding Playwright end‐to‐end tests, and refactoring account creation logic. Key changes include updating transaction formatting in the UI, migrating database functions to dedicated service modules, and updating API endpoints and test suites to handle errors and validations better.

Reviewed Changes

Copilot reviewed 33 out of 38 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/TransactionsCard.tsx Updated currency formatting using a helper function
scripts/build-schemas.js Modified generator block injection for Prisma client output
playwright.config.ts Added a new Playwright configuration file with updated settings
pages/view/[viewid].tsx & pages/manage/[userid].tsx Updated backend service calls for fetching and updating account info
pages/api/* Refactored API endpoints to work with service modules and handle errors consistently
pages/index.tsx Enhanced homepage layout with a new description card and image
tests/CreateAccountForm.test.tsx Updated tests to match changes in the CreateAccountForm component
CONTRIBUTING.md, .github/workflows/ci.yml, .eslintrc.js Updated documentation and configuration for style/CI improvements
Files not reviewed (5)
  • .eslintignore: Language not supported
  • .prettierignore: Language not supported
  • package.json: Language not supported
  • prisma/schema.prisma: Language not supported
  • scripts/test-all.sh: Language not supported
Comments suppressed due to low confidence (1)

scripts/build-schemas.js:38

  • Ensure that the injected indentation and line breaks in the generator block match the existing schema formatting. Misaligned formatting could potentially lead to issues with the Prisma generator block parsing.
const indentedOutput = '\n  output   = "../node_modules/@prisma/client"';

res.status(409).send('Account already exists.')
} else {
res.status(500).send(`Error - ${error.message}`)
const { username, password } = req.body
Copy link

Copilot AI Apr 25, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The API no longer verifies that the password confirmation matches the provided password. Consider adding a check to ensure that both password fields (e.g., pass and pass2, or a new confirmation field) match before proceeding.

Copilot uses AI. Check for mistakes.
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is intended behavior. Needs verification on UI side only.

@BadPirate BadPirate merged commit 8618fbc into main Apr 25, 2025
1 check failed
@BadPirate BadPirate deleted the codex branch April 25, 2025 23:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants