Skip to content

test(nip66): add integration tests for RelayMonitorWorker - #733

Merged
cameri merged 1 commit into
mainfrom
nip66-integration-tests
Aug 18, 2026
Merged

test(nip66): add integration tests for RelayMonitorWorker#733
cameri merged 1 commit into
mainfrom
nip66-integration-tests

Conversation

@Ferryx349

Copy link
Copy Markdown
Collaborator

Description

This PR:

  • Adds @nip-66 Cucumber integration tests for RelayMonitorWorker
  • Exercises real Redis snapshot storage and live probing of the integration relay
  • Covers enabled/disabled modes, target fallback, and invalid target skipping

Related Issue

#724 (merged)

Motivation and Context

How Has This Been Tested?

pnpm run docker:test:integration -- --tags @nip-66

Screenshots (if appropriate):

Types of changes

  • Non-functional change (docs, style, minor refactor)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my code changes.
  • I added a changeset, or this is docs-only and I added an empty changeset.
  • All new and existing tests passed.

Add @nip-66 Cucumber scenarios that exercise the monitor worker against
real Redis and the integration relay, covering snapshot storage, disabled
mode, target fallback, and invalid target skipping.
@changeset-bot

changeset-bot Bot commented Aug 17, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: d72782c

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
nostream Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@coveralls

Copy link
Copy Markdown
Collaborator

Coverage Status

coverage: 70.601% (+0.4%) from 70.218% — nip66-integration-tests into main

Copilot AI left a comment

Copy link
Copy Markdown

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 adds Cucumber-based integration coverage for the NIP-66 RelayMonitorWorker, validating that probe runs persist the latest snapshot into Redis and that target selection behaves correctly (explicit targets, info.relay_url fallback, and invalid target skipping).

Changes:

  • Added @nip-66 Cucumber feature scenarios asserting snapshot persistence/status and target resolution behavior.
  • Added step definitions that run RelayMonitorWorker against the integration relay and poll Redis for the latest snapshot.
  • Added a changeset describing the new integration test coverage.

Reviewed changes

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

File Description
test/integration/features/nip-66/nip-66.feature.ts Adds step definitions that start RelayMonitorWorker, configure settings, and assert Redis snapshot contents.
test/integration/features/nip-66/nip-66.feature Adds NIP-66 feature scenarios for enabled/disabled behavior, fallback targeting, and invalid target skipping.
.changeset/nip66-relay-monitor-integration-tests.md Declares a patch changeset documenting the added integration tests.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +54 to +55
const createMonitorProcess = (): NodeJS.Process => new EventEmitter() as NodeJS.Process

@cameri
cameri merged commit 9fb1c10 into main Aug 18, 2026
21 checks passed
@cameri
cameri deleted the nip66-integration-tests branch August 18, 2026 02:11
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.

4 participants