File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed
Sources/RediStack/Commands
Tests/RediStackIntegrationTests/Commands Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ extension RedisCommand {
4646
4747 /// [PUBSUB NUMPAT](https://redis.io/commands/pubsub#codepubsub-numpatcode)
4848 public static func pubsubNumpat( ) -> RedisCommand < Int > {
49- return . init( keyword: " PUBSUB NUMPAT " , arguments: [ ] )
49+ return . init( keyword: " PUBSUB " , arguments: [ . init ( bulk : " NUMPAT " ) ] )
5050 }
5151
5252 /// [PUBSUB NUMSUB](https://redis.io/commands/pubsub#codepubsub-numsub-channel-1--channel-ncode)
Original file line number Diff line number Diff line change @@ -190,6 +190,14 @@ final class RedisPubSubCommandsTests: RediStackIntegrationTestCase {
190190 self . waitForExpectations ( timeout: 1 )
191191 }
192192
193+ func test_pubSubNumpat( ) throws {
194+ let queryConnection = try self . makeNewConnection ( )
195+ defer { try ? queryConnection. close ( ) . wait ( ) }
196+
197+ let numPat = try queryConnection. send ( . pubsubNumpat( ) ) . wait ( )
198+ XCTAssertGreaterThanOrEqual ( numPat, 0 )
199+ }
200+
193201 func test_pubSubChannels( ) throws {
194202 let fn = #function
195203 let subscriber = try self . makeNewConnection ( )
You can’t perform that action at this time.
0 commit comments