Skip to content

feat: add additional retained match patterns with multiple wildcards to abstract.js#103

Merged
robertsLando merged 2 commits intomainfrom
added-abstract-patterns
May 22, 2025
Merged

feat: add additional retained match patterns with multiple wildcards to abstract.js#103
robertsLando merged 2 commits intomainfrom
added-abstract-patterns

Conversation

@seriousme
Copy link
Copy Markdown
Contributor

This PR adds additional patterns with multiple wildcards to match on retained messages to the test suite in abstract.js
It aims to prevent regressions on moscajs/aedes-persistence-redis#123

Kind regards,
Hans

Comment thread abstract.js
Comment on lines +125 to +138
test('look up retained messages with a + as first element', async t => {
t.plan(1)
await matchRetainedWithPattern(t, '+/world')
})

test('look up retained messages with +/#', async t => {
t.plan(1)
await matchRetainedWithPattern(t, '+/#')
})

test('look up retained messages with a + and # pattern with some in between', async t => {
t.plan(1)
await matchRetainedWithPattern(t, 'hello/+/world/#', { topic: 'hello/there/world/creatures' })
})
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

shouldn't this also test passing an array of patterns?

@robertsLando robertsLando merged commit 2d69505 into main May 22, 2025
6 checks passed
@robertsLando robertsLando deleted the added-abstract-patterns branch May 22, 2025 09:08
@robertsLando
Copy link
Copy Markdown
Member

Minor release?

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