Skip to content

new skill for serenity tests, adjusted skills for claude#287

Open
jasonmorais wants to merge 6 commits into
mainfrom
jason/serenity-skill
Open

new skill for serenity tests, adjusted skills for claude#287
jasonmorais wants to merge 6 commits into
mainfrom
jason/serenity-skill

Conversation

@jasonmorais

@jasonmorais jasonmorais commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

…ing symlinks across the .claude and also fixing an old symlink

Summary by Sourcery

Add a new Serenity/JS verification skill and documentation, integrate skills with Claude via symlinks, and refine staff role permission handling and tests.

New Features:

  • Introduce a Serenity tests agent skill with suite-specific setup and writing guides for acceptance API, acceptance UI, E2E, and shared page objects.
  • Expose additional queue storage service and JSON schema typings from the service-queue-storage package and add a coverage test script for application services.

Bug Fixes:

  • Fix an old repository lookup error path by marking the not-found error with a specific name.
  • Ensure GitHub and Claude skill symlinks are defined consistently across skills documentation and directories.

Enhancements:

  • Document agent skills integration for multiple AI assistants, including GitHub Copilot and Claude, and clarify managed skill set conventions.
  • Refine staff role creation and update tests with strongly typed mock permissions, more precise not-found handling, and new unit tests for permission application helpers.
  • Reorder various imports and exports for consistency and type-only usage, and bump the shell-quote dependency version.
  • Exclude Claude and GitHub skill directories from Snyk scanning and wire new Serenity-related verification tasks into the workspace configuration.

Build:

  • Adjust Snyk test and monitor scripts to ignore AI skill directories and keep vulnerability scanning focused on source code.

Tests:

  • Add focused unit tests for staff role permission application helpers and enable coverage reporting for application-services tests.

…ing symlinks across the .claude and also fixing an old symlink
@sourcery-ai

sourcery-ai Bot commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Reviewer's Guide

Adds a new Serenity/JS-focused serenity-tests skill plus repo-specific workflow skills, wires them into both Copilot and Claude via symlinked discovery folders, and introduces stronger typing and tests around staff-role permission application while making several smaller dependency, export, Snyk, and formatting adjustments.

File-Level Changes

Change Details Files
Introduce serenity-tests skill and documentation for Serenity/JS verification suites and shared page-object patterns.
  • Document new serenity-tests skill in skills README with purpose, use cases, and reference links.
  • Add SKILL.md describing core Serenity/JS verification model, suite selection, shared conventions, and validation commands.
  • Add suite-specific setup and writing guides for acceptance API, acceptance UI, and E2E browser suites.
  • Add shared page-object pattern reference emphasizing PageAdapter-backed, runtime-neutral page objects.
.agents/skills/README.md
.agents/skills/serenity-tests/SKILL.md
.agents/skills/serenity-tests/references/acceptance-api/setup.md
.agents/skills/serenity-tests/references/acceptance-api/writing-tests.md
.agents/skills/serenity-tests/references/acceptance-ui/setup.md
.agents/skills/serenity-tests/references/acceptance-ui/writing-tests.md
.agents/skills/serenity-tests/references/e2e/setup.md
.agents/skills/serenity-tests/references/e2e/writing-tests.md
.agents/skills/serenity-tests/references/page-objects/pattern.md
Extend AI assistant skill discovery to Claude and add repo-specific workflow skills for planning, diff review, and validation.
  • Add .claude/skills tree with symlinks for all managed skills, mirroring .github/skills for Claude discovery.
  • Update skills README to describe .claude/skills as a symlinked discovery location and update managed-skill definition accordingly.
  • Add new repo-specific workflow skills plan-feature, review-diff, and run-validation under .agents/skills with corresponding Copilot and Claude symlinks.
  • Broaden "Integration with GitHub Copilot" section to "Integration with AI Assistants" and clarify generic agent skills integration story.
.agents/skills/README.md
.claude/skills/ant-design
.claude/skills/antd
.claude/skills/apollo-client
.claude/skills/apollo-mcp-server
.claude/skills/apollo-server
.claude/skills/browser-testing-with-devtools
.claude/skills/cellix-tdd
.claude/skills/graphql-operations
.claude/skills/graphql-schema
.claude/skills/madr-enforcement
.claude/skills/mongodb-connection
.claude/skills/mongodb-mcp-setup
.claude/skills/mongodb-query-optimizer
.claude/skills/mongodb-schema-design
.claude/skills/plan-feature
.claude/skills/queue-authoring
.claude/skills/review-diff
.claude/skills/run-validation
.claude/skills/serenity-tests
.claude/skills/turbo-graph-optimization
.claude/skills/turborepo
.claude/skills/typescript-advanced-types
.claude/skills/vercel-react-best-practices
.claude/skills/vitest
.github/skills/apollo-client
.github/skills/apollo-mcp-server
.github/skills/apollo-server
.github/skills/graphql-operations
.github/skills/graphql-schema
.github/skills/plan-feature
.github/skills/review-diff
.github/skills/run-validation
.github/skills/serenity-tests
.github/skills/typescript-advanced-types
.github/skills/vercel-react-best-practices
Improve typing and test coverage for staff-role permission application in application services.
  • Introduce dedicated mock permission type aliases in create and update staff-role tests instead of loose Record<string, boolean>.
  • Adjust mock repository getByRoleName in create tests to reject with a typed NotFoundError when no role exists.
  • Align tests with new StaffRoleCommandPermissions type imported from apply-permissions.ts.
  • Add focused unit tests for applyCommunityPermissions, applyUserPermissions, applyRolePermissions, applyFinancePermissions, and applyTechAdminPermissions.
  • Tighten key iteration in tests by casting Object.keys results to specific permission key unions.
packages/ocom/application-services/src/contexts/user/staff-role/create.test.ts
packages/ocom/application-services/src/contexts/user/staff-role/update.test.ts
packages/ocom/application-services/src/contexts/user/staff-role/apply-permissions.test.ts
Tidy exports, imports, and queue-storage surface area around JSON schema types and queue service types.
  • Reorder exports in service-queue-storage index to expose JSON schema utility types before internal queue type exports while keeping logging helpers grouped.
  • Adjust import ordering in queue-related consumers to follow project style (types before values) and maintain consistent named import ordering.
  • Ensure queue storage-related tests and support files use the updated import shapes.
packages/cellix/service-queue-storage/src/index.ts
packages/ocom-verification/e2e-tests/src/shared/support/queue-storage.ts
packages/ocom-verification/acceptance-api/src/mock-application-services.ts
packages/ocom/service-queue-storage/src/schemas/inbound/end-user-update.ts
Refine verification and tooling configuration (scripts, deps, Snyk, workspace overrides) to support new suites and dependency updates.
  • Add test:coverage script to @ocom/application-services to run Vitest with coverage.
  • Exclude .claude and .github directories from Snyk test and monitor commands to avoid scanning generated/agent artifacts.
  • Bump shell-quote override from 1.8.4 to 1.9.0 in pnpm workspace to pick up fixes/security updates.
  • Update lockfile, turbo, biome, and knip configs accordingly (implicit in diff).
packages/ocom/application-services/package.json
package.json
pnpm-workspace.yaml
pnpm-lock.yaml
turbo.json
biome.json
knip.json
Minor code style and robustness cleanups in tests and infrastructure adapters.
  • Collapse some multi-line attemptsTo and predicate expressions to single lines where consistent with style guides.
  • Adjust import ordering in several files (e.g., OAuth2 mock server index, community domain adapter) to maintain local conventions.
  • Update E2E and acceptance step-definition imports to group support helpers together and avoid circular or out-of-order imports.
packages/ocom-verification/acceptance-ui/src/contexts/community/step-definitions/create-community.steps.tsx
packages/ocom-verification/e2e-tests/src/shared/support/queue-storage.ts
packages/ocom/persistence/src/datasources/domain/community/community/community.domain-adapter.ts
apps/server-oauth2-mock/src/index.ts
packages/ocom-verification/e2e-tests/src/contexts/community/step-definitions/create-community.steps.ts

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@jasonmorais jasonmorais marked this pull request as ready for review June 25, 2026 13:01
@jasonmorais jasonmorais requested a review from a team June 25, 2026 13:01

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Hey - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@jasonmorais jasonmorais requested a review from a team as a code owner June 25, 2026 14:19
# Conflicts:
#	knip.json
#	pnpm-lock.yaml
#	pnpm-workspace.yaml
…ty-skill

# Conflicts:
#	.agents/skills/README.md
# Conflicts:
#	packages/cellix/service-queue-storage/src/register-queues.ts
@jasonmorais jasonmorais changed the title initial commit for new skill for serenity tests, along with centraliz… new skill for serenity tests, adjusted skills for claude Jul 2, 2026
@jasonmorais

Copy link
Copy Markdown
Contributor Author

@sourcery-ai review

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Hey - I've left some high level feedback:

Fixed security issues:

  • @opentelemetry/exporter-prometheus (link)

  • The MockCommunityPermissions / MockUserPermissions (and related mock permission types) are now duplicated between create.test.ts and update.test.ts; consider extracting these mocks into a shared test helper to avoid divergence and keep future changes to the permission surface in one place.

  • Some newly changed statements (for example, the onSave handler in acceptance-ui and the long boolean condition in waitForCommunityCreationQueueMessage) were compressed onto a single line, which makes them harder to read and review; consider reverting these to multi-line formatting for clarity.

Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- The `MockCommunityPermissions` / `MockUserPermissions` (and related mock permission types) are now duplicated between `create.test.ts` and `update.test.ts`; consider extracting these mocks into a shared test helper to avoid divergence and keep future changes to the permission surface in one place.
- Some newly changed statements (for example, the `onSave` handler in `acceptance-ui` and the long boolean condition in `waitForCommunityCreationQueueMessage`) were compressed onto a single line, which makes them harder to read and review; consider reverting these to multi-line formatting for clarity.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

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.

3 participants