Commit c72ffa84 authored by Marc Gravell's avatar Marc Gravell

mark HighPriority as [Obsolete]; more releaes note updates

parent 135bd613
...@@ -15,12 +15,14 @@ ...@@ -15,12 +15,14 @@
the `Subscribe` method has a new overload *without* a handler parameter which returns a `ChannelMessageQueue`, which provides `async` ordered access to messsages) the `Subscribe` method has a new overload *without* a handler parameter which returns a `ChannelMessageQueue`, which provides `async` ordered access to messsages)
- internal: the network architecture has moved to use `System.IO.Pipelines`; this has allowed us to simplify and unify a lot of the network code, and in particular - internal: the network architecture has moved to use `System.IO.Pipelines`; this has allowed us to simplify and unify a lot of the network code, and in particular
fix a lot of problems relating to how the library worked with TLS and/or .NETStandard fix a lot of problems relating to how the library worked with TLS and/or .NETStandard
- change: as a result of the `System.IO.Pipelines` change, the error-reporting on timeouts is now much simpler and clearer; the [timeouts documentation](Timeouts.md) has been updated
- removed: the `HighPriority` (queue-jumping) flag is now deprecated
- internal: most buffers internally now make use of pooled memory; `RedisValue` no longer pre-emptively allocates buffers - internal: most buffers internally now make use of pooled memory; `RedisValue` no longer pre-emptively allocates buffers
- added: asynchronous operations now have full support for reporting timeouts - added: asynchronous operations now have full support for reporting timeouts
- added: new APIs now exist to work with pooled memory without allocations - `RedisValue.CreateFrom(MemoryStream)` and `operator` support for `Memory<byte>` and `ReadOnlyMemory<byte>`; and `IDatabase.StringGetLease[Async](...)`, `IDatabase.HashGetLease[Async](...)`, `Lease<byte>.AsStream()`) - added: new APIs now exist to work with pooled memory without allocations - `RedisValue.CreateFrom(MemoryStream)` and `operator` support for `Memory<byte>` and `ReadOnlyMemory<byte>`; and `IDatabase.StringGetLease[Async](...)`, `IDatabase.HashGetLease[Async](...)`, `Lease<byte>.AsStream()`)
- added: ["streams"](https://redis.io/topics/streams-intro) support (thanks to [ttingen](https://github.com/ttingen) for their contribution) - added: ["streams"](https://redis.io/topics/streams-intro) support (thanks to [ttingen](https://github.com/ttingen) for their contribution)
- various missing commands / overloads have been added - various missing commands / overloads have been added
- a *lot* of general bugs and issues have been resolved - fix: a *lot* of general bugs and issues have been resolved
a more complete list of issues addressed can be seen in [this tracking issue](https://github.com/StackExchange/StackExchange.Redis/issues/871) a more complete list of issues addressed can be seen in [this tracking issue](https://github.com/StackExchange/StackExchange.Redis/issues/871)
......
...@@ -12,10 +12,11 @@ public enum CommandFlags ...@@ -12,10 +12,11 @@ public enum CommandFlags
/// Default behaviour. /// Default behaviour.
/// </summary> /// </summary>
None = 0, None = 0,
/// <summary> /// <summary>
/// From 2.0, this flag is not used /// From 2.0, this flag is not used
/// </summary> /// </summary>
// [Obsolete("From 2.0, this flag is not used", false)] [Obsolete("From 2.0, this flag is not used", false)]
HighPriority = 1, HighPriority = 1,
/// <summary> /// <summary>
/// The caller is not interested in the result; the caller will immediately receive a default-value /// The caller is not interested in the result; the caller will immediately receive a default-value
......
...@@ -47,8 +47,8 @@ public void CreateTransaction() ...@@ -47,8 +47,8 @@ public void CreateTransaction()
[Fact] [Fact]
public void DebugObject() public void DebugObject()
{ {
wrapper.DebugObject("key", CommandFlags.HighPriority); wrapper.DebugObject("key", CommandFlags.None);
mock.Verify(_ => _.DebugObject("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.DebugObject("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -61,145 +61,145 @@ public void Get_Database() ...@@ -61,145 +61,145 @@ public void Get_Database()
[Fact] [Fact]
public void HashDecrement_1() public void HashDecrement_1()
{ {
wrapper.HashDecrement("key", "hashField", 123, CommandFlags.HighPriority); wrapper.HashDecrement("key", "hashField", 123, CommandFlags.None);
mock.Verify(_ => _.HashDecrement("prefix:key", "hashField", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.HashDecrement("prefix:key", "hashField", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void HashDecrement_2() public void HashDecrement_2()
{ {
wrapper.HashDecrement("key", "hashField", 1.23, CommandFlags.HighPriority); wrapper.HashDecrement("key", "hashField", 1.23, CommandFlags.None);
mock.Verify(_ => _.HashDecrement("prefix:key", "hashField", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.HashDecrement("prefix:key", "hashField", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void HashDelete_1() public void HashDelete_1()
{ {
wrapper.HashDelete("key", "hashField", CommandFlags.HighPriority); wrapper.HashDelete("key", "hashField", CommandFlags.None);
mock.Verify(_ => _.HashDelete("prefix:key", "hashField", CommandFlags.HighPriority)); mock.Verify(_ => _.HashDelete("prefix:key", "hashField", CommandFlags.None));
} }
[Fact] [Fact]
public void HashDelete_2() public void HashDelete_2()
{ {
RedisValue[] hashFields = new RedisValue[0]; RedisValue[] hashFields = new RedisValue[0];
wrapper.HashDelete("key", hashFields, CommandFlags.HighPriority); wrapper.HashDelete("key", hashFields, CommandFlags.None);
mock.Verify(_ => _.HashDelete("prefix:key", hashFields, CommandFlags.HighPriority)); mock.Verify(_ => _.HashDelete("prefix:key", hashFields, CommandFlags.None));
} }
[Fact] [Fact]
public void HashExists() public void HashExists()
{ {
wrapper.HashExists("key", "hashField", CommandFlags.HighPriority); wrapper.HashExists("key", "hashField", CommandFlags.None);
mock.Verify(_ => _.HashExists("prefix:key", "hashField", CommandFlags.HighPriority)); mock.Verify(_ => _.HashExists("prefix:key", "hashField", CommandFlags.None));
} }
[Fact] [Fact]
public void HashGet_1() public void HashGet_1()
{ {
wrapper.HashGet("key", "hashField", CommandFlags.HighPriority); wrapper.HashGet("key", "hashField", CommandFlags.None);
mock.Verify(_ => _.HashGet("prefix:key", "hashField", CommandFlags.HighPriority)); mock.Verify(_ => _.HashGet("prefix:key", "hashField", CommandFlags.None));
} }
[Fact] [Fact]
public void HashGet_2() public void HashGet_2()
{ {
RedisValue[] hashFields = new RedisValue[0]; RedisValue[] hashFields = new RedisValue[0];
wrapper.HashGet("key", hashFields, CommandFlags.HighPriority); wrapper.HashGet("key", hashFields, CommandFlags.None);
mock.Verify(_ => _.HashGet("prefix:key", hashFields, CommandFlags.HighPriority)); mock.Verify(_ => _.HashGet("prefix:key", hashFields, CommandFlags.None));
} }
[Fact] [Fact]
public void HashGetAll() public void HashGetAll()
{ {
wrapper.HashGetAll("key", CommandFlags.HighPriority); wrapper.HashGetAll("key", CommandFlags.None);
mock.Verify(_ => _.HashGetAll("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.HashGetAll("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void HashIncrement_1() public void HashIncrement_1()
{ {
wrapper.HashIncrement("key", "hashField", 123, CommandFlags.HighPriority); wrapper.HashIncrement("key", "hashField", 123, CommandFlags.None);
mock.Verify(_ => _.HashIncrement("prefix:key", "hashField", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.HashIncrement("prefix:key", "hashField", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void HashIncrement_2() public void HashIncrement_2()
{ {
wrapper.HashIncrement("key", "hashField", 1.23, CommandFlags.HighPriority); wrapper.HashIncrement("key", "hashField", 1.23, CommandFlags.None);
mock.Verify(_ => _.HashIncrement("prefix:key", "hashField", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.HashIncrement("prefix:key", "hashField", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void HashKeys() public void HashKeys()
{ {
wrapper.HashKeys("key", CommandFlags.HighPriority); wrapper.HashKeys("key", CommandFlags.None);
mock.Verify(_ => _.HashKeys("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.HashKeys("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void HashLength() public void HashLength()
{ {
wrapper.HashLength("key", CommandFlags.HighPriority); wrapper.HashLength("key", CommandFlags.None);
mock.Verify(_ => _.HashLength("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.HashLength("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void HashScan() public void HashScan()
{ {
wrapper.HashScan("key", "pattern", 123, flags: CommandFlags.HighPriority); wrapper.HashScan("key", "pattern", 123, flags: CommandFlags.None);
mock.Verify(_ => _.HashScan("prefix:key", "pattern", 123, 0, 0, CommandFlags.HighPriority)); mock.Verify(_ => _.HashScan("prefix:key", "pattern", 123, 0, 0, CommandFlags.None));
} }
[Fact] [Fact]
public void HashSet_1() public void HashSet_1()
{ {
HashEntry[] hashFields = new HashEntry[0]; HashEntry[] hashFields = new HashEntry[0];
wrapper.HashSet("key", hashFields, CommandFlags.HighPriority); wrapper.HashSet("key", hashFields, CommandFlags.None);
mock.Verify(_ => _.HashSet("prefix:key", hashFields, CommandFlags.HighPriority)); mock.Verify(_ => _.HashSet("prefix:key", hashFields, CommandFlags.None));
} }
[Fact] [Fact]
public void HashSet_2() public void HashSet_2()
{ {
wrapper.HashSet("key", "hashField", "value", When.Exists, CommandFlags.HighPriority); wrapper.HashSet("key", "hashField", "value", When.Exists, CommandFlags.None);
mock.Verify(_ => _.HashSet("prefix:key", "hashField", "value", When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.HashSet("prefix:key", "hashField", "value", When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void HashValues() public void HashValues()
{ {
wrapper.HashValues("key", CommandFlags.HighPriority); wrapper.HashValues("key", CommandFlags.None);
mock.Verify(_ => _.HashValues("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.HashValues("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void HyperLogLogAdd_1() public void HyperLogLogAdd_1()
{ {
wrapper.HyperLogLogAdd("key", "value", CommandFlags.HighPriority); wrapper.HyperLogLogAdd("key", "value", CommandFlags.None);
mock.Verify(_ => _.HyperLogLogAdd("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.HyperLogLogAdd("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void HyperLogLogAdd_2() public void HyperLogLogAdd_2()
{ {
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
wrapper.HyperLogLogAdd("key", values, CommandFlags.HighPriority); wrapper.HyperLogLogAdd("key", values, CommandFlags.None);
mock.Verify(_ => _.HyperLogLogAdd("prefix:key", values, CommandFlags.HighPriority)); mock.Verify(_ => _.HyperLogLogAdd("prefix:key", values, CommandFlags.None));
} }
[Fact] [Fact]
public void HyperLogLogLength() public void HyperLogLogLength()
{ {
wrapper.HyperLogLogLength("key", CommandFlags.HighPriority); wrapper.HyperLogLogLength("key", CommandFlags.None);
mock.Verify(_ => _.HyperLogLogLength("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.HyperLogLogLength("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void HyperLogLogMerge_1() public void HyperLogLogMerge_1()
{ {
wrapper.HyperLogLogMerge("destination", "first", "second", CommandFlags.HighPriority); wrapper.HyperLogLogMerge("destination", "first", "second", CommandFlags.None);
mock.Verify(_ => _.HyperLogLogMerge("prefix:destination", "prefix:first", "prefix:second", CommandFlags.HighPriority)); mock.Verify(_ => _.HyperLogLogMerge("prefix:destination", "prefix:first", "prefix:second", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -207,22 +207,22 @@ public void HyperLogLogMerge_2() ...@@ -207,22 +207,22 @@ public void HyperLogLogMerge_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.HyperLogLogMerge("destination", keys, CommandFlags.HighPriority); wrapper.HyperLogLogMerge("destination", keys, CommandFlags.None);
mock.Verify(_ => _.HyperLogLogMerge("prefix:destination", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.HyperLogLogMerge("prefix:destination", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void IdentifyEndpoint() public void IdentifyEndpoint()
{ {
wrapper.IdentifyEndpoint("key", CommandFlags.HighPriority); wrapper.IdentifyEndpoint("key", CommandFlags.None);
mock.Verify(_ => _.IdentifyEndpoint("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.IdentifyEndpoint("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void KeyDelete_1() public void KeyDelete_1()
{ {
wrapper.KeyDelete("key", CommandFlags.HighPriority); wrapper.KeyDelete("key", CommandFlags.None);
mock.Verify(_ => _.KeyDelete("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyDelete("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -230,60 +230,60 @@ public void KeyDelete_2() ...@@ -230,60 +230,60 @@ public void KeyDelete_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.KeyDelete(keys, CommandFlags.HighPriority); wrapper.KeyDelete(keys, CommandFlags.None);
mock.Verify(_ => _.KeyDelete(It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.KeyDelete(It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void KeyDump() public void KeyDump()
{ {
wrapper.KeyDump("key", CommandFlags.HighPriority); wrapper.KeyDump("key", CommandFlags.None);
mock.Verify(_ => _.KeyDump("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyDump("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void KeyExists() public void KeyExists()
{ {
wrapper.KeyExists("key", CommandFlags.HighPriority); wrapper.KeyExists("key", CommandFlags.None);
mock.Verify(_ => _.KeyExists("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyExists("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void KeyExpire_1() public void KeyExpire_1()
{ {
TimeSpan expiry = TimeSpan.FromSeconds(123); TimeSpan expiry = TimeSpan.FromSeconds(123);
wrapper.KeyExpire("key", expiry, CommandFlags.HighPriority); wrapper.KeyExpire("key", expiry, CommandFlags.None);
mock.Verify(_ => _.KeyExpire("prefix:key", expiry, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyExpire("prefix:key", expiry, CommandFlags.None));
} }
[Fact] [Fact]
public void KeyExpire_2() public void KeyExpire_2()
{ {
DateTime expiry = DateTime.Now; DateTime expiry = DateTime.Now;
wrapper.KeyExpire("key", expiry, CommandFlags.HighPriority); wrapper.KeyExpire("key", expiry, CommandFlags.None);
mock.Verify(_ => _.KeyExpire("prefix:key", expiry, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyExpire("prefix:key", expiry, CommandFlags.None));
} }
[Fact] [Fact]
public void KeyMigrate() public void KeyMigrate()
{ {
EndPoint toServer = new IPEndPoint(IPAddress.Loopback, 123); EndPoint toServer = new IPEndPoint(IPAddress.Loopback, 123);
wrapper.KeyMigrate("key", toServer, 123, 456, MigrateOptions.Copy, CommandFlags.HighPriority); wrapper.KeyMigrate("key", toServer, 123, 456, MigrateOptions.Copy, CommandFlags.None);
mock.Verify(_ => _.KeyMigrate("prefix:key", toServer, 123, 456, MigrateOptions.Copy, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyMigrate("prefix:key", toServer, 123, 456, MigrateOptions.Copy, CommandFlags.None));
} }
[Fact] [Fact]
public void KeyMove() public void KeyMove()
{ {
wrapper.KeyMove("key", 123, CommandFlags.HighPriority); wrapper.KeyMove("key", 123, CommandFlags.None);
mock.Verify(_ => _.KeyMove("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyMove("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void KeyPersist() public void KeyPersist()
{ {
wrapper.KeyPersist("key", CommandFlags.HighPriority); wrapper.KeyPersist("key", CommandFlags.None);
mock.Verify(_ => _.KeyPersist("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyPersist("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -295,8 +295,8 @@ public void KeyRandom() ...@@ -295,8 +295,8 @@ public void KeyRandom()
[Fact] [Fact]
public void KeyRename() public void KeyRename()
{ {
wrapper.KeyRename("key", "newKey", When.Exists, CommandFlags.HighPriority); wrapper.KeyRename("key", "newKey", When.Exists, CommandFlags.None);
mock.Verify(_ => _.KeyRename("prefix:key", "prefix:newKey", When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyRename("prefix:key", "prefix:newKey", When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
...@@ -304,166 +304,166 @@ public void KeyRestore() ...@@ -304,166 +304,166 @@ public void KeyRestore()
{ {
byte[] value = new byte[0]; byte[] value = new byte[0];
TimeSpan expiry = TimeSpan.FromSeconds(123); TimeSpan expiry = TimeSpan.FromSeconds(123);
wrapper.KeyRestore("key", value, expiry, CommandFlags.HighPriority); wrapper.KeyRestore("key", value, expiry, CommandFlags.None);
mock.Verify(_ => _.KeyRestore("prefix:key", value, expiry, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyRestore("prefix:key", value, expiry, CommandFlags.None));
} }
[Fact] [Fact]
public void KeyTimeToLive() public void KeyTimeToLive()
{ {
wrapper.KeyTimeToLive("key", CommandFlags.HighPriority); wrapper.KeyTimeToLive("key", CommandFlags.None);
mock.Verify(_ => _.KeyTimeToLive("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyTimeToLive("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void KeyType() public void KeyType()
{ {
wrapper.KeyType("key", CommandFlags.HighPriority); wrapper.KeyType("key", CommandFlags.None);
mock.Verify(_ => _.KeyType("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyType("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void ListGetByIndex() public void ListGetByIndex()
{ {
wrapper.ListGetByIndex("key", 123, CommandFlags.HighPriority); wrapper.ListGetByIndex("key", 123, CommandFlags.None);
mock.Verify(_ => _.ListGetByIndex("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.ListGetByIndex("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void ListInsertAfter() public void ListInsertAfter()
{ {
wrapper.ListInsertAfter("key", "pivot", "value", CommandFlags.HighPriority); wrapper.ListInsertAfter("key", "pivot", "value", CommandFlags.None);
mock.Verify(_ => _.ListInsertAfter("prefix:key", "pivot", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.ListInsertAfter("prefix:key", "pivot", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void ListInsertBefore() public void ListInsertBefore()
{ {
wrapper.ListInsertBefore("key", "pivot", "value", CommandFlags.HighPriority); wrapper.ListInsertBefore("key", "pivot", "value", CommandFlags.None);
mock.Verify(_ => _.ListInsertBefore("prefix:key", "pivot", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.ListInsertBefore("prefix:key", "pivot", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void ListLeftPop() public void ListLeftPop()
{ {
wrapper.ListLeftPop("key", CommandFlags.HighPriority); wrapper.ListLeftPop("key", CommandFlags.None);
mock.Verify(_ => _.ListLeftPop("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.ListLeftPop("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void ListLeftPush_1() public void ListLeftPush_1()
{ {
wrapper.ListLeftPush("key", "value", When.Exists, CommandFlags.HighPriority); wrapper.ListLeftPush("key", "value", When.Exists, CommandFlags.None);
mock.Verify(_ => _.ListLeftPush("prefix:key", "value", When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.ListLeftPush("prefix:key", "value", When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void ListLeftPush_2() public void ListLeftPush_2()
{ {
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
wrapper.ListLeftPush("key", values, CommandFlags.HighPriority); wrapper.ListLeftPush("key", values, CommandFlags.None);
mock.Verify(_ => _.ListLeftPush("prefix:key", values, CommandFlags.HighPriority)); mock.Verify(_ => _.ListLeftPush("prefix:key", values, CommandFlags.None));
} }
[Fact] [Fact]
public void ListLength() public void ListLength()
{ {
wrapper.ListLength("key", CommandFlags.HighPriority); wrapper.ListLength("key", CommandFlags.None);
mock.Verify(_ => _.ListLength("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.ListLength("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void ListRange() public void ListRange()
{ {
wrapper.ListRange("key", 123, 456, CommandFlags.HighPriority); wrapper.ListRange("key", 123, 456, CommandFlags.None);
mock.Verify(_ => _.ListRange("prefix:key", 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.ListRange("prefix:key", 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void ListRemove() public void ListRemove()
{ {
wrapper.ListRemove("key", "value", 123, CommandFlags.HighPriority); wrapper.ListRemove("key", "value", 123, CommandFlags.None);
mock.Verify(_ => _.ListRemove("prefix:key", "value", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.ListRemove("prefix:key", "value", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void ListRightPop() public void ListRightPop()
{ {
wrapper.ListRightPop("key", CommandFlags.HighPriority); wrapper.ListRightPop("key", CommandFlags.None);
mock.Verify(_ => _.ListRightPop("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.ListRightPop("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void ListRightPopLeftPush() public void ListRightPopLeftPush()
{ {
wrapper.ListRightPopLeftPush("source", "destination", CommandFlags.HighPriority); wrapper.ListRightPopLeftPush("source", "destination", CommandFlags.None);
mock.Verify(_ => _.ListRightPopLeftPush("prefix:source", "prefix:destination", CommandFlags.HighPriority)); mock.Verify(_ => _.ListRightPopLeftPush("prefix:source", "prefix:destination", CommandFlags.None));
} }
[Fact] [Fact]
public void ListRightPush_1() public void ListRightPush_1()
{ {
wrapper.ListRightPush("key", "value", When.Exists, CommandFlags.HighPriority); wrapper.ListRightPush("key", "value", When.Exists, CommandFlags.None);
mock.Verify(_ => _.ListRightPush("prefix:key", "value", When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.ListRightPush("prefix:key", "value", When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void ListRightPush_2() public void ListRightPush_2()
{ {
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
wrapper.ListRightPush("key", values, CommandFlags.HighPriority); wrapper.ListRightPush("key", values, CommandFlags.None);
mock.Verify(_ => _.ListRightPush("prefix:key", values, CommandFlags.HighPriority)); mock.Verify(_ => _.ListRightPush("prefix:key", values, CommandFlags.None));
} }
[Fact] [Fact]
public void ListSetByIndex() public void ListSetByIndex()
{ {
wrapper.ListSetByIndex("key", 123, "value", CommandFlags.HighPriority); wrapper.ListSetByIndex("key", 123, "value", CommandFlags.None);
mock.Verify(_ => _.ListSetByIndex("prefix:key", 123, "value", CommandFlags.HighPriority)); mock.Verify(_ => _.ListSetByIndex("prefix:key", 123, "value", CommandFlags.None));
} }
[Fact] [Fact]
public void ListTrim() public void ListTrim()
{ {
wrapper.ListTrim("key", 123, 456, CommandFlags.HighPriority); wrapper.ListTrim("key", 123, 456, CommandFlags.None);
mock.Verify(_ => _.ListTrim("prefix:key", 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.ListTrim("prefix:key", 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void LockExtend() public void LockExtend()
{ {
TimeSpan expiry = TimeSpan.FromSeconds(123); TimeSpan expiry = TimeSpan.FromSeconds(123);
wrapper.LockExtend("key", "value", expiry, CommandFlags.HighPriority); wrapper.LockExtend("key", "value", expiry, CommandFlags.None);
mock.Verify(_ => _.LockExtend("prefix:key", "value", expiry, CommandFlags.HighPriority)); mock.Verify(_ => _.LockExtend("prefix:key", "value", expiry, CommandFlags.None));
} }
[Fact] [Fact]
public void LockQuery() public void LockQuery()
{ {
wrapper.LockQuery("key", CommandFlags.HighPriority); wrapper.LockQuery("key", CommandFlags.None);
mock.Verify(_ => _.LockQuery("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.LockQuery("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void LockRelease() public void LockRelease()
{ {
wrapper.LockRelease("key", "value", CommandFlags.HighPriority); wrapper.LockRelease("key", "value", CommandFlags.None);
mock.Verify(_ => _.LockRelease("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.LockRelease("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void LockTake() public void LockTake()
{ {
TimeSpan expiry = TimeSpan.FromSeconds(123); TimeSpan expiry = TimeSpan.FromSeconds(123);
wrapper.LockTake("key", "value", expiry, CommandFlags.HighPriority); wrapper.LockTake("key", "value", expiry, CommandFlags.None);
mock.Verify(_ => _.LockTake("prefix:key", "value", expiry, CommandFlags.HighPriority)); mock.Verify(_ => _.LockTake("prefix:key", "value", expiry, CommandFlags.None));
} }
[Fact] [Fact]
public void Publish() public void Publish()
{ {
wrapper.Publish("channel", "message", CommandFlags.HighPriority); wrapper.Publish("channel", "message", CommandFlags.None);
mock.Verify(_ => _.Publish("prefix:channel", "message", CommandFlags.HighPriority)); mock.Verify(_ => _.Publish("prefix:channel", "message", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -473,8 +473,8 @@ public void ScriptEvaluate_1() ...@@ -473,8 +473,8 @@ public void ScriptEvaluate_1()
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.ScriptEvaluate(hash, keys, values, CommandFlags.HighPriority); wrapper.ScriptEvaluate(hash, keys, values, CommandFlags.None);
mock.Verify(_ => _.ScriptEvaluate(hash, It.Is(valid), values, CommandFlags.HighPriority)); mock.Verify(_ => _.ScriptEvaluate(hash, It.Is(valid), values, CommandFlags.None));
} }
[Fact] [Fact]
...@@ -483,30 +483,30 @@ public void ScriptEvaluate_2() ...@@ -483,30 +483,30 @@ public void ScriptEvaluate_2()
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.ScriptEvaluate("script", keys, values, CommandFlags.HighPriority); wrapper.ScriptEvaluate("script", keys, values, CommandFlags.None);
mock.Verify(_ => _.ScriptEvaluate("script", It.Is(valid), values, CommandFlags.HighPriority)); mock.Verify(_ => _.ScriptEvaluate("script", It.Is(valid), values, CommandFlags.None));
} }
[Fact] [Fact]
public void SetAdd_1() public void SetAdd_1()
{ {
wrapper.SetAdd("key", "value", CommandFlags.HighPriority); wrapper.SetAdd("key", "value", CommandFlags.None);
mock.Verify(_ => _.SetAdd("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.SetAdd("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void SetAdd_2() public void SetAdd_2()
{ {
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
wrapper.SetAdd("key", values, CommandFlags.HighPriority); wrapper.SetAdd("key", values, CommandFlags.None);
mock.Verify(_ => _.SetAdd("prefix:key", values, CommandFlags.HighPriority)); mock.Verify(_ => _.SetAdd("prefix:key", values, CommandFlags.None));
} }
[Fact] [Fact]
public void SetCombine_1() public void SetCombine_1()
{ {
wrapper.SetCombine(SetOperation.Intersect, "first", "second", CommandFlags.HighPriority); wrapper.SetCombine(SetOperation.Intersect, "first", "second", CommandFlags.None);
mock.Verify(_ => _.SetCombine(SetOperation.Intersect, "prefix:first", "prefix:second", CommandFlags.HighPriority)); mock.Verify(_ => _.SetCombine(SetOperation.Intersect, "prefix:first", "prefix:second", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -514,15 +514,15 @@ public void SetCombine_2() ...@@ -514,15 +514,15 @@ public void SetCombine_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.SetCombine(SetOperation.Intersect, keys, CommandFlags.HighPriority); wrapper.SetCombine(SetOperation.Intersect, keys, CommandFlags.None);
mock.Verify(_ => _.SetCombine(SetOperation.Intersect, It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SetCombine(SetOperation.Intersect, It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void SetCombineAndStore_1() public void SetCombineAndStore_1()
{ {
wrapper.SetCombineAndStore(SetOperation.Intersect, "destination", "first", "second", CommandFlags.HighPriority); wrapper.SetCombineAndStore(SetOperation.Intersect, "destination", "first", "second", CommandFlags.None);
mock.Verify(_ => _.SetCombineAndStore(SetOperation.Intersect, "prefix:destination", "prefix:first", "prefix:second", CommandFlags.HighPriority)); mock.Verify(_ => _.SetCombineAndStore(SetOperation.Intersect, "prefix:destination", "prefix:first", "prefix:second", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -530,89 +530,89 @@ public void SetCombineAndStore_2() ...@@ -530,89 +530,89 @@ public void SetCombineAndStore_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.SetCombineAndStore(SetOperation.Intersect, "destination", keys, CommandFlags.HighPriority); wrapper.SetCombineAndStore(SetOperation.Intersect, "destination", keys, CommandFlags.None);
mock.Verify(_ => _.SetCombineAndStore(SetOperation.Intersect, "prefix:destination", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SetCombineAndStore(SetOperation.Intersect, "prefix:destination", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void SetContains() public void SetContains()
{ {
wrapper.SetContains("key", "value", CommandFlags.HighPriority); wrapper.SetContains("key", "value", CommandFlags.None);
mock.Verify(_ => _.SetContains("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.SetContains("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void SetLength() public void SetLength()
{ {
wrapper.SetLength("key", CommandFlags.HighPriority); wrapper.SetLength("key", CommandFlags.None);
mock.Verify(_ => _.SetLength("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.SetLength("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void SetMembers() public void SetMembers()
{ {
wrapper.SetMembers("key", CommandFlags.HighPriority); wrapper.SetMembers("key", CommandFlags.None);
mock.Verify(_ => _.SetMembers("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.SetMembers("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void SetMove() public void SetMove()
{ {
wrapper.SetMove("source", "destination", "value", CommandFlags.HighPriority); wrapper.SetMove("source", "destination", "value", CommandFlags.None);
mock.Verify(_ => _.SetMove("prefix:source", "prefix:destination", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.SetMove("prefix:source", "prefix:destination", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void SetPop_1() public void SetPop_1()
{ {
wrapper.SetPop("key", CommandFlags.HighPriority); wrapper.SetPop("key", CommandFlags.None);
mock.Verify(_ => _.SetPop("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.SetPop("prefix:key", CommandFlags.None));
wrapper.SetPop("key", 5, CommandFlags.HighPriority); wrapper.SetPop("key", 5, CommandFlags.None);
mock.Verify(_ => _.SetPop("prefix:key", 5, CommandFlags.HighPriority)); mock.Verify(_ => _.SetPop("prefix:key", 5, CommandFlags.None));
} }
[Fact] [Fact]
public void SetPop_2() public void SetPop_2()
{ {
wrapper.SetPop("key", 5, CommandFlags.HighPriority); wrapper.SetPop("key", 5, CommandFlags.None);
mock.Verify(_ => _.SetPop("prefix:key", 5, CommandFlags.HighPriority)); mock.Verify(_ => _.SetPop("prefix:key", 5, CommandFlags.None));
} }
[Fact] [Fact]
public void SetRandomMember() public void SetRandomMember()
{ {
wrapper.SetRandomMember("key", CommandFlags.HighPriority); wrapper.SetRandomMember("key", CommandFlags.None);
mock.Verify(_ => _.SetRandomMember("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.SetRandomMember("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void SetRandomMembers() public void SetRandomMembers()
{ {
wrapper.SetRandomMembers("key", 123, CommandFlags.HighPriority); wrapper.SetRandomMembers("key", 123, CommandFlags.None);
mock.Verify(_ => _.SetRandomMembers("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.SetRandomMembers("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void SetRemove_1() public void SetRemove_1()
{ {
wrapper.SetRemove("key", "value", CommandFlags.HighPriority); wrapper.SetRemove("key", "value", CommandFlags.None);
mock.Verify(_ => _.SetRemove("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.SetRemove("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void SetRemove_2() public void SetRemove_2()
{ {
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
wrapper.SetRemove("key", values, CommandFlags.HighPriority); wrapper.SetRemove("key", values, CommandFlags.None);
mock.Verify(_ => _.SetRemove("prefix:key", values, CommandFlags.HighPriority)); mock.Verify(_ => _.SetRemove("prefix:key", values, CommandFlags.None));
} }
[Fact] [Fact]
public void SetScan() public void SetScan()
{ {
wrapper.SetScan("key", "pattern", 123, flags: CommandFlags.HighPriority); wrapper.SetScan("key", "pattern", 123, flags: CommandFlags.None);
mock.Verify(_ => _.SetScan("prefix:key", "pattern", 123, 0, 0, CommandFlags.HighPriority)); mock.Verify(_ => _.SetScan("prefix:key", "pattern", 123, 0, 0, CommandFlags.None));
} }
[Fact] [Fact]
...@@ -621,11 +621,11 @@ public void Sort() ...@@ -621,11 +621,11 @@ public void Sort()
RedisValue[] get = new RedisValue[] { "a", "#" }; RedisValue[] get = new RedisValue[] { "a", "#" };
Expression<Func<RedisValue[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "#"; Expression<Func<RedisValue[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "#";
wrapper.Sort("key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", get, CommandFlags.HighPriority); wrapper.Sort("key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", get, CommandFlags.None);
wrapper.Sort("key", 123, 456, Order.Descending, SortType.Alphabetic, "by", get, CommandFlags.HighPriority); wrapper.Sort("key", 123, 456, Order.Descending, SortType.Alphabetic, "by", get, CommandFlags.None);
mock.Verify(_ => _.Sort("prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.Sort("prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", It.Is(valid), CommandFlags.None));
mock.Verify(_ => _.Sort("prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "prefix:by", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.Sort("prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "prefix:by", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
...@@ -634,33 +634,33 @@ public void SortAndStore() ...@@ -634,33 +634,33 @@ public void SortAndStore()
RedisValue[] get = new RedisValue[] { "a", "#" }; RedisValue[] get = new RedisValue[] { "a", "#" };
Expression<Func<RedisValue[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "#"; Expression<Func<RedisValue[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "#";
wrapper.SortAndStore("destination", "key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", get, CommandFlags.HighPriority); wrapper.SortAndStore("destination", "key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", get, CommandFlags.None);
wrapper.SortAndStore("destination", "key", 123, 456, Order.Descending, SortType.Alphabetic, "by", get, CommandFlags.HighPriority); wrapper.SortAndStore("destination", "key", 123, 456, Order.Descending, SortType.Alphabetic, "by", get, CommandFlags.None);
mock.Verify(_ => _.SortAndStore("prefix:destination", "prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SortAndStore("prefix:destination", "prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", It.Is(valid), CommandFlags.None));
mock.Verify(_ => _.SortAndStore("prefix:destination", "prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "prefix:by", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SortAndStore("prefix:destination", "prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "prefix:by", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetAdd_1() public void SortedSetAdd_1()
{ {
wrapper.SortedSetAdd("key", "member", 1.23, When.Exists, CommandFlags.HighPriority); wrapper.SortedSetAdd("key", "member", 1.23, When.Exists, CommandFlags.None);
mock.Verify(_ => _.SortedSetAdd("prefix:key", "member", 1.23, When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetAdd("prefix:key", "member", 1.23, When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetAdd_2() public void SortedSetAdd_2()
{ {
SortedSetEntry[] values = new SortedSetEntry[0]; SortedSetEntry[] values = new SortedSetEntry[0];
wrapper.SortedSetAdd("key", values, When.Exists, CommandFlags.HighPriority); wrapper.SortedSetAdd("key", values, When.Exists, CommandFlags.None);
mock.Verify(_ => _.SortedSetAdd("prefix:key", values, When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetAdd("prefix:key", values, When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetCombineAndStore_1() public void SortedSetCombineAndStore_1()
{ {
wrapper.SortedSetCombineAndStore(SetOperation.Intersect, "destination", "first", "second", Aggregate.Max, CommandFlags.HighPriority); wrapper.SortedSetCombineAndStore(SetOperation.Intersect, "destination", "first", "second", Aggregate.Max, CommandFlags.None);
mock.Verify(_ => _.SortedSetCombineAndStore(SetOperation.Intersect, "prefix:destination", "prefix:first", "prefix:second", Aggregate.Max, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetCombineAndStore(SetOperation.Intersect, "prefix:destination", "prefix:first", "prefix:second", Aggregate.Max, CommandFlags.None));
} }
[Fact] [Fact]
...@@ -668,324 +668,324 @@ public void SortedSetCombineAndStore_2() ...@@ -668,324 +668,324 @@ public void SortedSetCombineAndStore_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.SetCombineAndStore(SetOperation.Intersect, "destination", keys, CommandFlags.HighPriority); wrapper.SetCombineAndStore(SetOperation.Intersect, "destination", keys, CommandFlags.None);
mock.Verify(_ => _.SetCombineAndStore(SetOperation.Intersect, "prefix:destination", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SetCombineAndStore(SetOperation.Intersect, "prefix:destination", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetDecrement() public void SortedSetDecrement()
{ {
wrapper.SortedSetDecrement("key", "member", 1.23, CommandFlags.HighPriority); wrapper.SortedSetDecrement("key", "member", 1.23, CommandFlags.None);
mock.Verify(_ => _.SortedSetDecrement("prefix:key", "member", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetDecrement("prefix:key", "member", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetIncrement() public void SortedSetIncrement()
{ {
wrapper.SortedSetIncrement("key", "member", 1.23, CommandFlags.HighPriority); wrapper.SortedSetIncrement("key", "member", 1.23, CommandFlags.None);
mock.Verify(_ => _.SortedSetIncrement("prefix:key", "member", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetIncrement("prefix:key", "member", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetLength() public void SortedSetLength()
{ {
wrapper.SortedSetLength("key", 1.23, 1.23, Exclude.Start, CommandFlags.HighPriority); wrapper.SortedSetLength("key", 1.23, 1.23, Exclude.Start, CommandFlags.None);
mock.Verify(_ => _.SortedSetLength("prefix:key", 1.23, 1.23, Exclude.Start, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetLength("prefix:key", 1.23, 1.23, Exclude.Start, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetLengthByValue() public void SortedSetLengthByValue()
{ {
wrapper.SortedSetLengthByValue("key", "min", "max", Exclude.Start, CommandFlags.HighPriority); wrapper.SortedSetLengthByValue("key", "min", "max", Exclude.Start, CommandFlags.None);
mock.Verify(_ => _.SortedSetLengthByValue("prefix:key", "min", "max", Exclude.Start, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetLengthByValue("prefix:key", "min", "max", Exclude.Start, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByRank() public void SortedSetRangeByRank()
{ {
wrapper.SortedSetRangeByRank("key", 123, 456, Order.Descending, CommandFlags.HighPriority); wrapper.SortedSetRangeByRank("key", 123, 456, Order.Descending, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByRank("prefix:key", 123, 456, Order.Descending, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByRank("prefix:key", 123, 456, Order.Descending, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByRankWithScores() public void SortedSetRangeByRankWithScores()
{ {
wrapper.SortedSetRangeByRankWithScores("key", 123, 456, Order.Descending, CommandFlags.HighPriority); wrapper.SortedSetRangeByRankWithScores("key", 123, 456, Order.Descending, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByRankWithScores("prefix:key", 123, 456, Order.Descending, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByRankWithScores("prefix:key", 123, 456, Order.Descending, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByScore() public void SortedSetRangeByScore()
{ {
wrapper.SortedSetRangeByScore("key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority); wrapper.SortedSetRangeByScore("key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByScore("prefix:key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByScore("prefix:key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByScoreWithScores() public void SortedSetRangeByScoreWithScores()
{ {
wrapper.SortedSetRangeByScoreWithScores("key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority); wrapper.SortedSetRangeByScoreWithScores("key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByScoreWithScores("prefix:key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByScoreWithScores("prefix:key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByValue() public void SortedSetRangeByValue()
{ {
wrapper.SortedSetRangeByValue("key", "min", "max", Exclude.Start, 123, 456, CommandFlags.HighPriority); wrapper.SortedSetRangeByValue("key", "min", "max", Exclude.Start, 123, 456, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByValue("prefix:key", "min", "max", Exclude.Start, Order.Ascending, 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByValue("prefix:key", "min", "max", Exclude.Start, Order.Ascending, 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByValueDesc() public void SortedSetRangeByValueDesc()
{ {
wrapper.SortedSetRangeByValue("key", "min", "max", Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority); wrapper.SortedSetRangeByValue("key", "min", "max", Exclude.Start, Order.Descending, 123, 456, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByValue("prefix:key", "min", "max", Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByValue("prefix:key", "min", "max", Exclude.Start, Order.Descending, 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRank() public void SortedSetRank()
{ {
wrapper.SortedSetRank("key", "member", Order.Descending, CommandFlags.HighPriority); wrapper.SortedSetRank("key", "member", Order.Descending, CommandFlags.None);
mock.Verify(_ => _.SortedSetRank("prefix:key", "member", Order.Descending, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRank("prefix:key", "member", Order.Descending, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRemove_1() public void SortedSetRemove_1()
{ {
wrapper.SortedSetRemove("key", "member", CommandFlags.HighPriority); wrapper.SortedSetRemove("key", "member", CommandFlags.None);
mock.Verify(_ => _.SortedSetRemove("prefix:key", "member", CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRemove("prefix:key", "member", CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRemove_2() public void SortedSetRemove_2()
{ {
RedisValue[] members = new RedisValue[0]; RedisValue[] members = new RedisValue[0];
wrapper.SortedSetRemove("key", members, CommandFlags.HighPriority); wrapper.SortedSetRemove("key", members, CommandFlags.None);
mock.Verify(_ => _.SortedSetRemove("prefix:key", members, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRemove("prefix:key", members, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRemoveRangeByRank() public void SortedSetRemoveRangeByRank()
{ {
wrapper.SortedSetRemoveRangeByRank("key", 123, 456, CommandFlags.HighPriority); wrapper.SortedSetRemoveRangeByRank("key", 123, 456, CommandFlags.None);
mock.Verify(_ => _.SortedSetRemoveRangeByRank("prefix:key", 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRemoveRangeByRank("prefix:key", 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRemoveRangeByScore() public void SortedSetRemoveRangeByScore()
{ {
wrapper.SortedSetRemoveRangeByScore("key", 1.23, 1.23, Exclude.Start, CommandFlags.HighPriority); wrapper.SortedSetRemoveRangeByScore("key", 1.23, 1.23, Exclude.Start, CommandFlags.None);
mock.Verify(_ => _.SortedSetRemoveRangeByScore("prefix:key", 1.23, 1.23, Exclude.Start, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRemoveRangeByScore("prefix:key", 1.23, 1.23, Exclude.Start, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRemoveRangeByValue() public void SortedSetRemoveRangeByValue()
{ {
wrapper.SortedSetRemoveRangeByValue("key", "min", "max", Exclude.Start, CommandFlags.HighPriority); wrapper.SortedSetRemoveRangeByValue("key", "min", "max", Exclude.Start, CommandFlags.None);
mock.Verify(_ => _.SortedSetRemoveRangeByValue("prefix:key", "min", "max", Exclude.Start, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRemoveRangeByValue("prefix:key", "min", "max", Exclude.Start, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetScan() public void SortedSetScan()
{ {
wrapper.SortedSetScan("key", "pattern", 123, flags: CommandFlags.HighPriority); wrapper.SortedSetScan("key", "pattern", 123, flags: CommandFlags.None);
mock.Verify(_ => _.SortedSetScan("prefix:key", "pattern", 123, 0, 0, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetScan("prefix:key", "pattern", 123, 0, 0, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetScore() public void SortedSetScore()
{ {
wrapper.SortedSetScore("key", "member", CommandFlags.HighPriority); wrapper.SortedSetScore("key", "member", CommandFlags.None);
mock.Verify(_ => _.SortedSetScore("prefix:key", "member", CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetScore("prefix:key", "member", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamAcknowledge_1() public void StreamAcknowledge_1()
{ {
wrapper.StreamAcknowledge("key", "group", "0-0", CommandFlags.HighPriority); wrapper.StreamAcknowledge("key", "group", "0-0", CommandFlags.None);
mock.Verify(_ => _.StreamAcknowledge("prefix:key", "group", "0-0", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamAcknowledge("prefix:key", "group", "0-0", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamAcknowledge_2() public void StreamAcknowledge_2()
{ {
var messageIds = new RedisValue[] { "0-0", "0-1", "0-2" }; var messageIds = new RedisValue[] { "0-0", "0-1", "0-2" };
wrapper.StreamAcknowledge("key", "group", messageIds, CommandFlags.HighPriority); wrapper.StreamAcknowledge("key", "group", messageIds, CommandFlags.None);
mock.Verify(_ => _.StreamAcknowledge("prefix:key", "group", messageIds, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamAcknowledge("prefix:key", "group", messageIds, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamAdd_1() public void StreamAdd_1()
{ {
wrapper.StreamAdd("key", "field1", "value1", "*", 1000, true, CommandFlags.HighPriority); wrapper.StreamAdd("key", "field1", "value1", "*", 1000, true, CommandFlags.None);
mock.Verify(_ => _.StreamAdd("prefix:key", "field1", "value1", "*", 1000, true, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamAdd("prefix:key", "field1", "value1", "*", 1000, true, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamAdd_2() public void StreamAdd_2()
{ {
var fields = new NameValueEntry[0]; var fields = new NameValueEntry[0];
wrapper.StreamAdd("key", fields, "*", 1000, true, CommandFlags.HighPriority); wrapper.StreamAdd("key", fields, "*", 1000, true, CommandFlags.None);
mock.Verify(_ => _.StreamAdd("prefix:key", fields, "*", 1000, true, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamAdd("prefix:key", fields, "*", 1000, true, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamClaimMessages() public void StreamClaimMessages()
{ {
var messageIds = new RedisValue[0]; var messageIds = new RedisValue[0];
wrapper.StreamClaim("key", "group", "consumer", 1000, messageIds, CommandFlags.HighPriority); wrapper.StreamClaim("key", "group", "consumer", 1000, messageIds, CommandFlags.None);
mock.Verify(_ => _.StreamClaim("prefix:key", "group", "consumer", 1000, messageIds, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamClaim("prefix:key", "group", "consumer", 1000, messageIds, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamClaimMessagesReturningIds() public void StreamClaimMessagesReturningIds()
{ {
var messageIds = new RedisValue[0]; var messageIds = new RedisValue[0];
wrapper.StreamClaimIdsOnly("key", "group", "consumer", 1000, messageIds, CommandFlags.HighPriority); wrapper.StreamClaimIdsOnly("key", "group", "consumer", 1000, messageIds, CommandFlags.None);
mock.Verify(_ => _.StreamClaimIdsOnly("prefix:key", "group", "consumer", 1000, messageIds, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamClaimIdsOnly("prefix:key", "group", "consumer", 1000, messageIds, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamConsumerGroupSetPosition() public void StreamConsumerGroupSetPosition()
{ {
wrapper.StreamConsumerGroupSetPosition("key", "group", StreamPosition.Beginning, CommandFlags.HighPriority); wrapper.StreamConsumerGroupSetPosition("key", "group", StreamPosition.Beginning, CommandFlags.None);
mock.Verify(_ => _.StreamConsumerGroupSetPosition("prefix:key", "group", StreamPosition.Beginning, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamConsumerGroupSetPosition("prefix:key", "group", StreamPosition.Beginning, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamConsumerInfoGet() public void StreamConsumerInfoGet()
{ {
wrapper.StreamConsumerInfo("key", "group", CommandFlags.HighPriority); wrapper.StreamConsumerInfo("key", "group", CommandFlags.None);
mock.Verify(_ => _.StreamConsumerInfo("prefix:key", "group", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamConsumerInfo("prefix:key", "group", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamCreateConsumerGroup() public void StreamCreateConsumerGroup()
{ {
wrapper.StreamCreateConsumerGroup("key", "group", StreamPosition.Beginning, CommandFlags.HighPriority); wrapper.StreamCreateConsumerGroup("key", "group", StreamPosition.Beginning, CommandFlags.None);
mock.Verify(_ => _.StreamCreateConsumerGroup("prefix:key", "group", StreamPosition.Beginning, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamCreateConsumerGroup("prefix:key", "group", StreamPosition.Beginning, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamGroupInfoGet() public void StreamGroupInfoGet()
{ {
wrapper.StreamGroupInfo("key", CommandFlags.HighPriority); wrapper.StreamGroupInfo("key", CommandFlags.None);
mock.Verify(_ => _.StreamGroupInfo("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamGroupInfo("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamInfoGet() public void StreamInfoGet()
{ {
wrapper.StreamInfo("key", CommandFlags.HighPriority); wrapper.StreamInfo("key", CommandFlags.None);
mock.Verify(_ => _.StreamInfo("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamInfo("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamLength() public void StreamLength()
{ {
wrapper.StreamLength("key", CommandFlags.HighPriority); wrapper.StreamLength("key", CommandFlags.None);
mock.Verify(_ => _.StreamLength("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamLength("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamMessagesDelete() public void StreamMessagesDelete()
{ {
var messageIds = new RedisValue[0] { }; var messageIds = new RedisValue[0] { };
wrapper.StreamDelete("key", messageIds, CommandFlags.HighPriority); wrapper.StreamDelete("key", messageIds, CommandFlags.None);
mock.Verify(_ => _.StreamDelete("prefix:key", messageIds, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamDelete("prefix:key", messageIds, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamDeleteConsumer() public void StreamDeleteConsumer()
{ {
wrapper.StreamDeleteConsumer("key", "group", "consumer", CommandFlags.HighPriority); wrapper.StreamDeleteConsumer("key", "group", "consumer", CommandFlags.None);
mock.Verify(_ => _.StreamDeleteConsumer("prefix:key", "group", "consumer", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamDeleteConsumer("prefix:key", "group", "consumer", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamDeleteConsumerGroup() public void StreamDeleteConsumerGroup()
{ {
wrapper.StreamDeleteConsumerGroup("key", "group", CommandFlags.HighPriority); wrapper.StreamDeleteConsumerGroup("key", "group", CommandFlags.None);
mock.Verify(_ => _.StreamDeleteConsumerGroup("prefix:key", "group", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamDeleteConsumerGroup("prefix:key", "group", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamPendingInfoGet() public void StreamPendingInfoGet()
{ {
wrapper.StreamPending("key", "group", CommandFlags.HighPriority); wrapper.StreamPending("key", "group", CommandFlags.None);
mock.Verify(_ => _.StreamPending("prefix:key", "group", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamPending("prefix:key", "group", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamPendingMessageInfoGet() public void StreamPendingMessageInfoGet()
{ {
wrapper.StreamPendingMessages("key", "group", 10, RedisValue.Null, "-", "+", CommandFlags.HighPriority); wrapper.StreamPendingMessages("key", "group", 10, RedisValue.Null, "-", "+", CommandFlags.None);
mock.Verify(_ => _.StreamPendingMessages("prefix:key", "group", 10, RedisValue.Null, "-", "+", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamPendingMessages("prefix:key", "group", 10, RedisValue.Null, "-", "+", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamRange() public void StreamRange()
{ {
wrapper.StreamRange("key", "-", "+", null, Order.Ascending, CommandFlags.HighPriority); wrapper.StreamRange("key", "-", "+", null, Order.Ascending, CommandFlags.None);
mock.Verify(_ => _.StreamRange("prefix:key", "-", "+", null, Order.Ascending, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamRange("prefix:key", "-", "+", null, Order.Ascending, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamRead_1() public void StreamRead_1()
{ {
var streamPositions = new StreamPosition[0] { }; var streamPositions = new StreamPosition[0] { };
wrapper.StreamRead(streamPositions, null, CommandFlags.HighPriority); wrapper.StreamRead(streamPositions, null, CommandFlags.None);
mock.Verify(_ => _.StreamRead(streamPositions, null, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamRead(streamPositions, null, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamRead_2() public void StreamRead_2()
{ {
wrapper.StreamRead("key", "0-0", null, CommandFlags.HighPriority); wrapper.StreamRead("key", "0-0", null, CommandFlags.None);
mock.Verify(_ => _.StreamRead("prefix:key", "0-0", null, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamRead("prefix:key", "0-0", null, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamStreamReadGroup_1() public void StreamStreamReadGroup_1()
{ {
wrapper.StreamReadGroup("key", "group", "consumer", "0-0", 10, CommandFlags.HighPriority); wrapper.StreamReadGroup("key", "group", "consumer", "0-0", 10, CommandFlags.None);
mock.Verify(_ => _.StreamReadGroup("prefix:key", "group", "consumer", "0-0", 10, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamReadGroup("prefix:key", "group", "consumer", "0-0", 10, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamStreamReadGroup_2() public void StreamStreamReadGroup_2()
{ {
var streamPositions = new StreamPosition[0] { }; var streamPositions = new StreamPosition[0] { };
wrapper.StreamReadGroup(streamPositions, "group", "consumer", 10, CommandFlags.HighPriority); wrapper.StreamReadGroup(streamPositions, "group", "consumer", 10, CommandFlags.None);
mock.Verify(_ => _.StreamReadGroup(streamPositions, "group", "consumer", 10, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamReadGroup(streamPositions, "group", "consumer", 10, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamTrim() public void StreamTrim()
{ {
wrapper.StreamTrim("key", 1000, true, CommandFlags.HighPriority); wrapper.StreamTrim("key", 1000, true, CommandFlags.None);
mock.Verify(_ => _.StreamTrim("prefix:key", 1000, true, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamTrim("prefix:key", 1000, true, CommandFlags.None));
} }
[Fact] [Fact]
public void StringAppend() public void StringAppend()
{ {
wrapper.StringAppend("key", "value", CommandFlags.HighPriority); wrapper.StringAppend("key", "value", CommandFlags.None);
mock.Verify(_ => _.StringAppend("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.StringAppend("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void StringBitCount() public void StringBitCount()
{ {
wrapper.StringBitCount("key", 123, 456, CommandFlags.HighPriority); wrapper.StringBitCount("key", 123, 456, CommandFlags.None);
mock.Verify(_ => _.StringBitCount("prefix:key", 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.StringBitCount("prefix:key", 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void StringBitOperation_1() public void StringBitOperation_1()
{ {
wrapper.StringBitOperation(Bitwise.Xor, "destination", "first", "second", CommandFlags.HighPriority); wrapper.StringBitOperation(Bitwise.Xor, "destination", "first", "second", CommandFlags.None);
mock.Verify(_ => _.StringBitOperation(Bitwise.Xor, "prefix:destination", "prefix:first", "prefix:second", CommandFlags.HighPriority)); mock.Verify(_ => _.StringBitOperation(Bitwise.Xor, "prefix:destination", "prefix:first", "prefix:second", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -993,36 +993,36 @@ public void StringBitOperation_2() ...@@ -993,36 +993,36 @@ public void StringBitOperation_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.StringBitOperation(Bitwise.Xor, "destination", keys, CommandFlags.HighPriority); wrapper.StringBitOperation(Bitwise.Xor, "destination", keys, CommandFlags.None);
mock.Verify(_ => _.StringBitOperation(Bitwise.Xor, "prefix:destination", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.StringBitOperation(Bitwise.Xor, "prefix:destination", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void StringBitPosition() public void StringBitPosition()
{ {
wrapper.StringBitPosition("key", true, 123, 456, CommandFlags.HighPriority); wrapper.StringBitPosition("key", true, 123, 456, CommandFlags.None);
mock.Verify(_ => _.StringBitPosition("prefix:key", true, 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.StringBitPosition("prefix:key", true, 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void StringDecrement_1() public void StringDecrement_1()
{ {
wrapper.StringDecrement("key", 123, CommandFlags.HighPriority); wrapper.StringDecrement("key", 123, CommandFlags.None);
mock.Verify(_ => _.StringDecrement("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.StringDecrement("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void StringDecrement_2() public void StringDecrement_2()
{ {
wrapper.StringDecrement("key", 1.23, CommandFlags.HighPriority); wrapper.StringDecrement("key", 1.23, CommandFlags.None);
mock.Verify(_ => _.StringDecrement("prefix:key", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.StringDecrement("prefix:key", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void StringGet_1() public void StringGet_1()
{ {
wrapper.StringGet("key", CommandFlags.HighPriority); wrapper.StringGet("key", CommandFlags.None);
mock.Verify(_ => _.StringGet("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StringGet("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -1030,65 +1030,65 @@ public void StringGet_2() ...@@ -1030,65 +1030,65 @@ public void StringGet_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.StringGet(keys, CommandFlags.HighPriority); wrapper.StringGet(keys, CommandFlags.None);
mock.Verify(_ => _.StringGet(It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.StringGet(It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void StringGetBit() public void StringGetBit()
{ {
wrapper.StringGetBit("key", 123, CommandFlags.HighPriority); wrapper.StringGetBit("key", 123, CommandFlags.None);
mock.Verify(_ => _.StringGetBit("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.StringGetBit("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void StringGetRange() public void StringGetRange()
{ {
wrapper.StringGetRange("key", 123, 456, CommandFlags.HighPriority); wrapper.StringGetRange("key", 123, 456, CommandFlags.None);
mock.Verify(_ => _.StringGetRange("prefix:key", 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.StringGetRange("prefix:key", 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void StringGetSet() public void StringGetSet()
{ {
wrapper.StringGetSet("key", "value", CommandFlags.HighPriority); wrapper.StringGetSet("key", "value", CommandFlags.None);
mock.Verify(_ => _.StringGetSet("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.StringGetSet("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void StringGetWithExpiry() public void StringGetWithExpiry()
{ {
wrapper.StringGetWithExpiry("key", CommandFlags.HighPriority); wrapper.StringGetWithExpiry("key", CommandFlags.None);
mock.Verify(_ => _.StringGetWithExpiry("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StringGetWithExpiry("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void StringIncrement_1() public void StringIncrement_1()
{ {
wrapper.StringIncrement("key", 123, CommandFlags.HighPriority); wrapper.StringIncrement("key", 123, CommandFlags.None);
mock.Verify(_ => _.StringIncrement("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.StringIncrement("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void StringIncrement_2() public void StringIncrement_2()
{ {
wrapper.StringIncrement("key", 1.23, CommandFlags.HighPriority); wrapper.StringIncrement("key", 1.23, CommandFlags.None);
mock.Verify(_ => _.StringIncrement("prefix:key", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.StringIncrement("prefix:key", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void StringLength() public void StringLength()
{ {
wrapper.StringLength("key", CommandFlags.HighPriority); wrapper.StringLength("key", CommandFlags.None);
mock.Verify(_ => _.StringLength("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StringLength("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void StringSet_1() public void StringSet_1()
{ {
TimeSpan expiry = TimeSpan.FromSeconds(123); TimeSpan expiry = TimeSpan.FromSeconds(123);
wrapper.StringSet("key", "value", expiry, When.Exists, CommandFlags.HighPriority); wrapper.StringSet("key", "value", expiry, When.Exists, CommandFlags.None);
mock.Verify(_ => _.StringSet("prefix:key", "value", expiry, When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.StringSet("prefix:key", "value", expiry, When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
...@@ -1096,22 +1096,22 @@ public void StringSet_2() ...@@ -1096,22 +1096,22 @@ public void StringSet_2()
{ {
KeyValuePair<RedisKey, RedisValue>[] values = new KeyValuePair<RedisKey, RedisValue>[] { new KeyValuePair<RedisKey, RedisValue>("a", "x"), new KeyValuePair<RedisKey, RedisValue>("b", "y") }; KeyValuePair<RedisKey, RedisValue>[] values = new KeyValuePair<RedisKey, RedisValue>[] { new KeyValuePair<RedisKey, RedisValue>("a", "x"), new KeyValuePair<RedisKey, RedisValue>("b", "y") };
Expression<Func<KeyValuePair<RedisKey, RedisValue>[], bool>> valid = _ => _.Length == 2 && _[0].Key == "prefix:a" && _[0].Value == "x" && _[1].Key == "prefix:b" && _[1].Value == "y"; Expression<Func<KeyValuePair<RedisKey, RedisValue>[], bool>> valid = _ => _.Length == 2 && _[0].Key == "prefix:a" && _[0].Value == "x" && _[1].Key == "prefix:b" && _[1].Value == "y";
wrapper.StringSet(values, When.Exists, CommandFlags.HighPriority); wrapper.StringSet(values, When.Exists, CommandFlags.None);
mock.Verify(_ => _.StringSet(It.Is(valid), When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.StringSet(It.Is(valid), When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void StringSetBit() public void StringSetBit()
{ {
wrapper.StringSetBit("key", 123, true, CommandFlags.HighPriority); wrapper.StringSetBit("key", 123, true, CommandFlags.None);
mock.Verify(_ => _.StringSetBit("prefix:key", 123, true, CommandFlags.HighPriority)); mock.Verify(_ => _.StringSetBit("prefix:key", 123, true, CommandFlags.None));
} }
[Fact] [Fact]
public void StringSetRange() public void StringSetRange()
{ {
wrapper.StringSetRange("key", 123, "value", CommandFlags.HighPriority); wrapper.StringSetRange("key", 123, "value", CommandFlags.None);
mock.Verify(_ => _.StringSetRange("prefix:key", 123, "value", CommandFlags.HighPriority)); mock.Verify(_ => _.StringSetRange("prefix:key", 123, "value", CommandFlags.None));
} }
} }
} }
...@@ -75,15 +75,15 @@ public void AddCondition_StringNotEqual() ...@@ -75,15 +75,15 @@ public void AddCondition_StringNotEqual()
[Fact] [Fact]
public void ExecuteAsync() public void ExecuteAsync()
{ {
wrapper.ExecuteAsync(CommandFlags.HighPriority); wrapper.ExecuteAsync(CommandFlags.None);
mock.Verify(_ => _.ExecuteAsync(CommandFlags.HighPriority), Times.Once()); mock.Verify(_ => _.ExecuteAsync(CommandFlags.None), Times.Once());
} }
[Fact] [Fact]
public void Execute() public void Execute()
{ {
wrapper.Execute(CommandFlags.HighPriority); wrapper.Execute(CommandFlags.None);
mock.Verify(_ => _.Execute(CommandFlags.HighPriority), Times.Once()); mock.Verify(_ => _.Execute(CommandFlags.None), Times.Once());
} }
} }
#pragma warning restore RCS1047 // Non-asynchronous method name should not end with 'Async'. #pragma warning restore RCS1047 // Non-asynchronous method name should not end with 'Async'.
......
...@@ -26,145 +26,145 @@ public WrapperBaseTests() ...@@ -26,145 +26,145 @@ public WrapperBaseTests()
[Fact] [Fact]
public void DebugObjectAsync() public void DebugObjectAsync()
{ {
wrapper.DebugObjectAsync("key", CommandFlags.HighPriority); wrapper.DebugObjectAsync("key", CommandFlags.None);
mock.Verify(_ => _.DebugObjectAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.DebugObjectAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void HashDecrementAsync_1() public void HashDecrementAsync_1()
{ {
wrapper.HashDecrementAsync("key", "hashField", 123, CommandFlags.HighPriority); wrapper.HashDecrementAsync("key", "hashField", 123, CommandFlags.None);
mock.Verify(_ => _.HashDecrementAsync("prefix:key", "hashField", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.HashDecrementAsync("prefix:key", "hashField", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void HashDecrementAsync_2() public void HashDecrementAsync_2()
{ {
wrapper.HashDecrementAsync("key", "hashField", 1.23, CommandFlags.HighPriority); wrapper.HashDecrementAsync("key", "hashField", 1.23, CommandFlags.None);
mock.Verify(_ => _.HashDecrementAsync("prefix:key", "hashField", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.HashDecrementAsync("prefix:key", "hashField", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void HashDeleteAsync_1() public void HashDeleteAsync_1()
{ {
wrapper.HashDeleteAsync("key", "hashField", CommandFlags.HighPriority); wrapper.HashDeleteAsync("key", "hashField", CommandFlags.None);
mock.Verify(_ => _.HashDeleteAsync("prefix:key", "hashField", CommandFlags.HighPriority)); mock.Verify(_ => _.HashDeleteAsync("prefix:key", "hashField", CommandFlags.None));
} }
[Fact] [Fact]
public void HashDeleteAsync_2() public void HashDeleteAsync_2()
{ {
RedisValue[] hashFields = new RedisValue[0]; RedisValue[] hashFields = new RedisValue[0];
wrapper.HashDeleteAsync("key", hashFields, CommandFlags.HighPriority); wrapper.HashDeleteAsync("key", hashFields, CommandFlags.None);
mock.Verify(_ => _.HashDeleteAsync("prefix:key", hashFields, CommandFlags.HighPriority)); mock.Verify(_ => _.HashDeleteAsync("prefix:key", hashFields, CommandFlags.None));
} }
[Fact] [Fact]
public void HashExistsAsync() public void HashExistsAsync()
{ {
wrapper.HashExistsAsync("key", "hashField", CommandFlags.HighPriority); wrapper.HashExistsAsync("key", "hashField", CommandFlags.None);
mock.Verify(_ => _.HashExistsAsync("prefix:key", "hashField", CommandFlags.HighPriority)); mock.Verify(_ => _.HashExistsAsync("prefix:key", "hashField", CommandFlags.None));
} }
[Fact] [Fact]
public void HashGetAllAsync() public void HashGetAllAsync()
{ {
wrapper.HashGetAllAsync("key", CommandFlags.HighPriority); wrapper.HashGetAllAsync("key", CommandFlags.None);
mock.Verify(_ => _.HashGetAllAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.HashGetAllAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void HashGetAsync_1() public void HashGetAsync_1()
{ {
wrapper.HashGetAsync("key", "hashField", CommandFlags.HighPriority); wrapper.HashGetAsync("key", "hashField", CommandFlags.None);
mock.Verify(_ => _.HashGetAsync("prefix:key", "hashField", CommandFlags.HighPriority)); mock.Verify(_ => _.HashGetAsync("prefix:key", "hashField", CommandFlags.None));
} }
[Fact] [Fact]
public void HashGetAsync_2() public void HashGetAsync_2()
{ {
RedisValue[] hashFields = new RedisValue[0]; RedisValue[] hashFields = new RedisValue[0];
wrapper.HashGetAsync("key", hashFields, CommandFlags.HighPriority); wrapper.HashGetAsync("key", hashFields, CommandFlags.None);
mock.Verify(_ => _.HashGetAsync("prefix:key", hashFields, CommandFlags.HighPriority)); mock.Verify(_ => _.HashGetAsync("prefix:key", hashFields, CommandFlags.None));
} }
[Fact] [Fact]
public void HashIncrementAsync_1() public void HashIncrementAsync_1()
{ {
wrapper.HashIncrementAsync("key", "hashField", 123, CommandFlags.HighPriority); wrapper.HashIncrementAsync("key", "hashField", 123, CommandFlags.None);
mock.Verify(_ => _.HashIncrementAsync("prefix:key", "hashField", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.HashIncrementAsync("prefix:key", "hashField", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void HashIncrementAsync_2() public void HashIncrementAsync_2()
{ {
wrapper.HashIncrementAsync("key", "hashField", 1.23, CommandFlags.HighPriority); wrapper.HashIncrementAsync("key", "hashField", 1.23, CommandFlags.None);
mock.Verify(_ => _.HashIncrementAsync("prefix:key", "hashField", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.HashIncrementAsync("prefix:key", "hashField", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void HashKeysAsync() public void HashKeysAsync()
{ {
wrapper.HashKeysAsync("key", CommandFlags.HighPriority); wrapper.HashKeysAsync("key", CommandFlags.None);
mock.Verify(_ => _.HashKeysAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.HashKeysAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void HashLengthAsync() public void HashLengthAsync()
{ {
wrapper.HashLengthAsync("key", CommandFlags.HighPriority); wrapper.HashLengthAsync("key", CommandFlags.None);
mock.Verify(_ => _.HashLengthAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.HashLengthAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void HashSetAsync_1() public void HashSetAsync_1()
{ {
HashEntry[] hashFields = new HashEntry[0]; HashEntry[] hashFields = new HashEntry[0];
wrapper.HashSetAsync("key", hashFields, CommandFlags.HighPriority); wrapper.HashSetAsync("key", hashFields, CommandFlags.None);
mock.Verify(_ => _.HashSetAsync("prefix:key", hashFields, CommandFlags.HighPriority)); mock.Verify(_ => _.HashSetAsync("prefix:key", hashFields, CommandFlags.None));
} }
[Fact] [Fact]
public void HashSetAsync_2() public void HashSetAsync_2()
{ {
wrapper.HashSetAsync("key", "hashField", "value", When.Exists, CommandFlags.HighPriority); wrapper.HashSetAsync("key", "hashField", "value", When.Exists, CommandFlags.None);
mock.Verify(_ => _.HashSetAsync("prefix:key", "hashField", "value", When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.HashSetAsync("prefix:key", "hashField", "value", When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void HashValuesAsync() public void HashValuesAsync()
{ {
wrapper.HashValuesAsync("key", CommandFlags.HighPriority); wrapper.HashValuesAsync("key", CommandFlags.None);
mock.Verify(_ => _.HashValuesAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.HashValuesAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void HyperLogLogAddAsync_1() public void HyperLogLogAddAsync_1()
{ {
wrapper.HyperLogLogAddAsync("key", "value", CommandFlags.HighPriority); wrapper.HyperLogLogAddAsync("key", "value", CommandFlags.None);
mock.Verify(_ => _.HyperLogLogAddAsync("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.HyperLogLogAddAsync("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void HyperLogLogAddAsync_2() public void HyperLogLogAddAsync_2()
{ {
var values = new RedisValue[0]; var values = new RedisValue[0];
wrapper.HyperLogLogAddAsync("key", values, CommandFlags.HighPriority); wrapper.HyperLogLogAddAsync("key", values, CommandFlags.None);
mock.Verify(_ => _.HyperLogLogAddAsync("prefix:key", values, CommandFlags.HighPriority)); mock.Verify(_ => _.HyperLogLogAddAsync("prefix:key", values, CommandFlags.None));
} }
[Fact] [Fact]
public void HyperLogLogLengthAsync() public void HyperLogLogLengthAsync()
{ {
wrapper.HyperLogLogLengthAsync("key", CommandFlags.HighPriority); wrapper.HyperLogLogLengthAsync("key", CommandFlags.None);
mock.Verify(_ => _.HyperLogLogLengthAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.HyperLogLogLengthAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void HyperLogLogMergeAsync_1() public void HyperLogLogMergeAsync_1()
{ {
wrapper.HyperLogLogMergeAsync("destination", "first", "second", CommandFlags.HighPriority); wrapper.HyperLogLogMergeAsync("destination", "first", "second", CommandFlags.None);
mock.Verify(_ => _.HyperLogLogMergeAsync("prefix:destination", "prefix:first", "prefix:second", CommandFlags.HighPriority)); mock.Verify(_ => _.HyperLogLogMergeAsync("prefix:destination", "prefix:first", "prefix:second", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -172,29 +172,29 @@ public void HyperLogLogMergeAsync_2() ...@@ -172,29 +172,29 @@ public void HyperLogLogMergeAsync_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.HyperLogLogMergeAsync("destination", keys, CommandFlags.HighPriority); wrapper.HyperLogLogMergeAsync("destination", keys, CommandFlags.None);
mock.Verify(_ => _.HyperLogLogMergeAsync("prefix:destination", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.HyperLogLogMergeAsync("prefix:destination", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void IdentifyEndpointAsync() public void IdentifyEndpointAsync()
{ {
wrapper.IdentifyEndpointAsync("key", CommandFlags.HighPriority); wrapper.IdentifyEndpointAsync("key", CommandFlags.None);
mock.Verify(_ => _.IdentifyEndpointAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.IdentifyEndpointAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void IsConnected() public void IsConnected()
{ {
wrapper.IsConnected("key", CommandFlags.HighPriority); wrapper.IsConnected("key", CommandFlags.None);
mock.Verify(_ => _.IsConnected("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.IsConnected("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void KeyDeleteAsync_1() public void KeyDeleteAsync_1()
{ {
wrapper.KeyDeleteAsync("key", CommandFlags.HighPriority); wrapper.KeyDeleteAsync("key", CommandFlags.None);
mock.Verify(_ => _.KeyDeleteAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyDeleteAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -202,60 +202,60 @@ public void KeyDeleteAsync_2() ...@@ -202,60 +202,60 @@ public void KeyDeleteAsync_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.KeyDeleteAsync(keys, CommandFlags.HighPriority); wrapper.KeyDeleteAsync(keys, CommandFlags.None);
mock.Verify(_ => _.KeyDeleteAsync(It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.KeyDeleteAsync(It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void KeyDumpAsync() public void KeyDumpAsync()
{ {
wrapper.KeyDumpAsync("key", CommandFlags.HighPriority); wrapper.KeyDumpAsync("key", CommandFlags.None);
mock.Verify(_ => _.KeyDumpAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyDumpAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void KeyExistsAsync() public void KeyExistsAsync()
{ {
wrapper.KeyExistsAsync("key", CommandFlags.HighPriority); wrapper.KeyExistsAsync("key", CommandFlags.None);
mock.Verify(_ => _.KeyExistsAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyExistsAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void KeyExpireAsync_1() public void KeyExpireAsync_1()
{ {
TimeSpan expiry = TimeSpan.FromSeconds(123); TimeSpan expiry = TimeSpan.FromSeconds(123);
wrapper.KeyExpireAsync("key", expiry, CommandFlags.HighPriority); wrapper.KeyExpireAsync("key", expiry, CommandFlags.None);
mock.Verify(_ => _.KeyExpireAsync("prefix:key", expiry, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyExpireAsync("prefix:key", expiry, CommandFlags.None));
} }
[Fact] [Fact]
public void KeyExpireAsync_2() public void KeyExpireAsync_2()
{ {
DateTime expiry = DateTime.Now; DateTime expiry = DateTime.Now;
wrapper.KeyExpireAsync("key", expiry, CommandFlags.HighPriority); wrapper.KeyExpireAsync("key", expiry, CommandFlags.None);
mock.Verify(_ => _.KeyExpireAsync("prefix:key", expiry, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyExpireAsync("prefix:key", expiry, CommandFlags.None));
} }
[Fact] [Fact]
public void KeyMigrateAsync() public void KeyMigrateAsync()
{ {
EndPoint toServer = new IPEndPoint(IPAddress.Loopback, 123); EndPoint toServer = new IPEndPoint(IPAddress.Loopback, 123);
wrapper.KeyMigrateAsync("key", toServer, 123, 456, MigrateOptions.Copy, CommandFlags.HighPriority); wrapper.KeyMigrateAsync("key", toServer, 123, 456, MigrateOptions.Copy, CommandFlags.None);
mock.Verify(_ => _.KeyMigrateAsync("prefix:key", toServer, 123, 456, MigrateOptions.Copy, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyMigrateAsync("prefix:key", toServer, 123, 456, MigrateOptions.Copy, CommandFlags.None));
} }
[Fact] [Fact]
public void KeyMoveAsync() public void KeyMoveAsync()
{ {
wrapper.KeyMoveAsync("key", 123, CommandFlags.HighPriority); wrapper.KeyMoveAsync("key", 123, CommandFlags.None);
mock.Verify(_ => _.KeyMoveAsync("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyMoveAsync("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void KeyPersistAsync() public void KeyPersistAsync()
{ {
wrapper.KeyPersistAsync("key", CommandFlags.HighPriority); wrapper.KeyPersistAsync("key", CommandFlags.None);
mock.Verify(_ => _.KeyPersistAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyPersistAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -267,8 +267,8 @@ public Task KeyRandomAsync() ...@@ -267,8 +267,8 @@ public Task KeyRandomAsync()
[Fact] [Fact]
public void KeyRenameAsync() public void KeyRenameAsync()
{ {
wrapper.KeyRenameAsync("key", "newKey", When.Exists, CommandFlags.HighPriority); wrapper.KeyRenameAsync("key", "newKey", When.Exists, CommandFlags.None);
mock.Verify(_ => _.KeyRenameAsync("prefix:key", "prefix:newKey", When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyRenameAsync("prefix:key", "prefix:newKey", When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
...@@ -276,166 +276,166 @@ public void KeyRestoreAsync() ...@@ -276,166 +276,166 @@ public void KeyRestoreAsync()
{ {
byte[] value = new byte[0]; byte[] value = new byte[0];
TimeSpan expiry = TimeSpan.FromSeconds(123); TimeSpan expiry = TimeSpan.FromSeconds(123);
wrapper.KeyRestoreAsync("key", value, expiry, CommandFlags.HighPriority); wrapper.KeyRestoreAsync("key", value, expiry, CommandFlags.None);
mock.Verify(_ => _.KeyRestoreAsync("prefix:key", value, expiry, CommandFlags.HighPriority)); mock.Verify(_ => _.KeyRestoreAsync("prefix:key", value, expiry, CommandFlags.None));
} }
[Fact] [Fact]
public void KeyTimeToLiveAsync() public void KeyTimeToLiveAsync()
{ {
wrapper.KeyTimeToLiveAsync("key", CommandFlags.HighPriority); wrapper.KeyTimeToLiveAsync("key", CommandFlags.None);
mock.Verify(_ => _.KeyTimeToLiveAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyTimeToLiveAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void KeyTypeAsync() public void KeyTypeAsync()
{ {
wrapper.KeyTypeAsync("key", CommandFlags.HighPriority); wrapper.KeyTypeAsync("key", CommandFlags.None);
mock.Verify(_ => _.KeyTypeAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.KeyTypeAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void ListGetByIndexAsync() public void ListGetByIndexAsync()
{ {
wrapper.ListGetByIndexAsync("key", 123, CommandFlags.HighPriority); wrapper.ListGetByIndexAsync("key", 123, CommandFlags.None);
mock.Verify(_ => _.ListGetByIndexAsync("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.ListGetByIndexAsync("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void ListInsertAfterAsync() public void ListInsertAfterAsync()
{ {
wrapper.ListInsertAfterAsync("key", "pivot", "value", CommandFlags.HighPriority); wrapper.ListInsertAfterAsync("key", "pivot", "value", CommandFlags.None);
mock.Verify(_ => _.ListInsertAfterAsync("prefix:key", "pivot", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.ListInsertAfterAsync("prefix:key", "pivot", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void ListInsertBeforeAsync() public void ListInsertBeforeAsync()
{ {
wrapper.ListInsertBeforeAsync("key", "pivot", "value", CommandFlags.HighPriority); wrapper.ListInsertBeforeAsync("key", "pivot", "value", CommandFlags.None);
mock.Verify(_ => _.ListInsertBeforeAsync("prefix:key", "pivot", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.ListInsertBeforeAsync("prefix:key", "pivot", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void ListLeftPopAsync() public void ListLeftPopAsync()
{ {
wrapper.ListLeftPopAsync("key", CommandFlags.HighPriority); wrapper.ListLeftPopAsync("key", CommandFlags.None);
mock.Verify(_ => _.ListLeftPopAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.ListLeftPopAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void ListLeftPushAsync_1() public void ListLeftPushAsync_1()
{ {
wrapper.ListLeftPushAsync("key", "value", When.Exists, CommandFlags.HighPriority); wrapper.ListLeftPushAsync("key", "value", When.Exists, CommandFlags.None);
mock.Verify(_ => _.ListLeftPushAsync("prefix:key", "value", When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.ListLeftPushAsync("prefix:key", "value", When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void ListLeftPushAsync_2() public void ListLeftPushAsync_2()
{ {
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
wrapper.ListLeftPushAsync("key", values, CommandFlags.HighPriority); wrapper.ListLeftPushAsync("key", values, CommandFlags.None);
mock.Verify(_ => _.ListLeftPushAsync("prefix:key", values, CommandFlags.HighPriority)); mock.Verify(_ => _.ListLeftPushAsync("prefix:key", values, CommandFlags.None));
} }
[Fact] [Fact]
public void ListLengthAsync() public void ListLengthAsync()
{ {
wrapper.ListLengthAsync("key", CommandFlags.HighPriority); wrapper.ListLengthAsync("key", CommandFlags.None);
mock.Verify(_ => _.ListLengthAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.ListLengthAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void ListRangeAsync() public void ListRangeAsync()
{ {
wrapper.ListRangeAsync("key", 123, 456, CommandFlags.HighPriority); wrapper.ListRangeAsync("key", 123, 456, CommandFlags.None);
mock.Verify(_ => _.ListRangeAsync("prefix:key", 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.ListRangeAsync("prefix:key", 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void ListRemoveAsync() public void ListRemoveAsync()
{ {
wrapper.ListRemoveAsync("key", "value", 123, CommandFlags.HighPriority); wrapper.ListRemoveAsync("key", "value", 123, CommandFlags.None);
mock.Verify(_ => _.ListRemoveAsync("prefix:key", "value", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.ListRemoveAsync("prefix:key", "value", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void ListRightPopAsync() public void ListRightPopAsync()
{ {
wrapper.ListRightPopAsync("key", CommandFlags.HighPriority); wrapper.ListRightPopAsync("key", CommandFlags.None);
mock.Verify(_ => _.ListRightPopAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.ListRightPopAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void ListRightPopLeftPushAsync() public void ListRightPopLeftPushAsync()
{ {
wrapper.ListRightPopLeftPushAsync("source", "destination", CommandFlags.HighPriority); wrapper.ListRightPopLeftPushAsync("source", "destination", CommandFlags.None);
mock.Verify(_ => _.ListRightPopLeftPushAsync("prefix:source", "prefix:destination", CommandFlags.HighPriority)); mock.Verify(_ => _.ListRightPopLeftPushAsync("prefix:source", "prefix:destination", CommandFlags.None));
} }
[Fact] [Fact]
public void ListRightPushAsync_1() public void ListRightPushAsync_1()
{ {
wrapper.ListRightPushAsync("key", "value", When.Exists, CommandFlags.HighPriority); wrapper.ListRightPushAsync("key", "value", When.Exists, CommandFlags.None);
mock.Verify(_ => _.ListRightPushAsync("prefix:key", "value", When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.ListRightPushAsync("prefix:key", "value", When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void ListRightPushAsync_2() public void ListRightPushAsync_2()
{ {
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
wrapper.ListRightPushAsync("key", values, CommandFlags.HighPriority); wrapper.ListRightPushAsync("key", values, CommandFlags.None);
mock.Verify(_ => _.ListRightPushAsync("prefix:key", values, CommandFlags.HighPriority)); mock.Verify(_ => _.ListRightPushAsync("prefix:key", values, CommandFlags.None));
} }
[Fact] [Fact]
public void ListSetByIndexAsync() public void ListSetByIndexAsync()
{ {
wrapper.ListSetByIndexAsync("key", 123, "value", CommandFlags.HighPriority); wrapper.ListSetByIndexAsync("key", 123, "value", CommandFlags.None);
mock.Verify(_ => _.ListSetByIndexAsync("prefix:key", 123, "value", CommandFlags.HighPriority)); mock.Verify(_ => _.ListSetByIndexAsync("prefix:key", 123, "value", CommandFlags.None));
} }
[Fact] [Fact]
public void ListTrimAsync() public void ListTrimAsync()
{ {
wrapper.ListTrimAsync("key", 123, 456, CommandFlags.HighPriority); wrapper.ListTrimAsync("key", 123, 456, CommandFlags.None);
mock.Verify(_ => _.ListTrimAsync("prefix:key", 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.ListTrimAsync("prefix:key", 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void LockExtendAsync() public void LockExtendAsync()
{ {
TimeSpan expiry = TimeSpan.FromSeconds(123); TimeSpan expiry = TimeSpan.FromSeconds(123);
wrapper.LockExtendAsync("key", "value", expiry, CommandFlags.HighPriority); wrapper.LockExtendAsync("key", "value", expiry, CommandFlags.None);
mock.Verify(_ => _.LockExtendAsync("prefix:key", "value", expiry, CommandFlags.HighPriority)); mock.Verify(_ => _.LockExtendAsync("prefix:key", "value", expiry, CommandFlags.None));
} }
[Fact] [Fact]
public void LockQueryAsync() public void LockQueryAsync()
{ {
wrapper.LockQueryAsync("key", CommandFlags.HighPriority); wrapper.LockQueryAsync("key", CommandFlags.None);
mock.Verify(_ => _.LockQueryAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.LockQueryAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void LockReleaseAsync() public void LockReleaseAsync()
{ {
wrapper.LockReleaseAsync("key", "value", CommandFlags.HighPriority); wrapper.LockReleaseAsync("key", "value", CommandFlags.None);
mock.Verify(_ => _.LockReleaseAsync("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.LockReleaseAsync("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void LockTakeAsync() public void LockTakeAsync()
{ {
TimeSpan expiry = TimeSpan.FromSeconds(123); TimeSpan expiry = TimeSpan.FromSeconds(123);
wrapper.LockTakeAsync("key", "value", expiry, CommandFlags.HighPriority); wrapper.LockTakeAsync("key", "value", expiry, CommandFlags.None);
mock.Verify(_ => _.LockTakeAsync("prefix:key", "value", expiry, CommandFlags.HighPriority)); mock.Verify(_ => _.LockTakeAsync("prefix:key", "value", expiry, CommandFlags.None));
} }
[Fact] [Fact]
public void PublishAsync() public void PublishAsync()
{ {
wrapper.PublishAsync("channel", "message", CommandFlags.HighPriority); wrapper.PublishAsync("channel", "message", CommandFlags.None);
mock.Verify(_ => _.PublishAsync("prefix:channel", "message", CommandFlags.HighPriority)); mock.Verify(_ => _.PublishAsync("prefix:channel", "message", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -445,8 +445,8 @@ public void ScriptEvaluateAsync_1() ...@@ -445,8 +445,8 @@ public void ScriptEvaluateAsync_1()
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.ScriptEvaluateAsync(hash, keys, values, CommandFlags.HighPriority); wrapper.ScriptEvaluateAsync(hash, keys, values, CommandFlags.None);
mock.Verify(_ => _.ScriptEvaluateAsync(hash, It.Is(valid), values, CommandFlags.HighPriority)); mock.Verify(_ => _.ScriptEvaluateAsync(hash, It.Is(valid), values, CommandFlags.None));
} }
[Fact] [Fact]
...@@ -455,30 +455,30 @@ public void ScriptEvaluateAsync_2() ...@@ -455,30 +455,30 @@ public void ScriptEvaluateAsync_2()
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.ScriptEvaluateAsync("script", keys, values, CommandFlags.HighPriority); wrapper.ScriptEvaluateAsync("script", keys, values, CommandFlags.None);
mock.Verify(_ => _.ScriptEvaluateAsync("script", It.Is(valid), values, CommandFlags.HighPriority)); mock.Verify(_ => _.ScriptEvaluateAsync("script", It.Is(valid), values, CommandFlags.None));
} }
[Fact] [Fact]
public void SetAddAsync_1() public void SetAddAsync_1()
{ {
wrapper.SetAddAsync("key", "value", CommandFlags.HighPriority); wrapper.SetAddAsync("key", "value", CommandFlags.None);
mock.Verify(_ => _.SetAddAsync("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.SetAddAsync("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void SetAddAsync_2() public void SetAddAsync_2()
{ {
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
wrapper.SetAddAsync("key", values, CommandFlags.HighPriority); wrapper.SetAddAsync("key", values, CommandFlags.None);
mock.Verify(_ => _.SetAddAsync("prefix:key", values, CommandFlags.HighPriority)); mock.Verify(_ => _.SetAddAsync("prefix:key", values, CommandFlags.None));
} }
[Fact] [Fact]
public void SetCombineAndStoreAsync_1() public void SetCombineAndStoreAsync_1()
{ {
wrapper.SetCombineAndStoreAsync(SetOperation.Intersect, "destination", "first", "second", CommandFlags.HighPriority); wrapper.SetCombineAndStoreAsync(SetOperation.Intersect, "destination", "first", "second", CommandFlags.None);
mock.Verify(_ => _.SetCombineAndStoreAsync(SetOperation.Intersect, "prefix:destination", "prefix:first", "prefix:second", CommandFlags.HighPriority)); mock.Verify(_ => _.SetCombineAndStoreAsync(SetOperation.Intersect, "prefix:destination", "prefix:first", "prefix:second", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -486,15 +486,15 @@ public void SetCombineAndStoreAsync_2() ...@@ -486,15 +486,15 @@ public void SetCombineAndStoreAsync_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.SetCombineAndStoreAsync(SetOperation.Intersect, "destination", keys, CommandFlags.HighPriority); wrapper.SetCombineAndStoreAsync(SetOperation.Intersect, "destination", keys, CommandFlags.None);
mock.Verify(_ => _.SetCombineAndStoreAsync(SetOperation.Intersect, "prefix:destination", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SetCombineAndStoreAsync(SetOperation.Intersect, "prefix:destination", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void SetCombineAsync_1() public void SetCombineAsync_1()
{ {
wrapper.SetCombineAsync(SetOperation.Intersect, "first", "second", CommandFlags.HighPriority); wrapper.SetCombineAsync(SetOperation.Intersect, "first", "second", CommandFlags.None);
mock.Verify(_ => _.SetCombineAsync(SetOperation.Intersect, "prefix:first", "prefix:second", CommandFlags.HighPriority)); mock.Verify(_ => _.SetCombineAsync(SetOperation.Intersect, "prefix:first", "prefix:second", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -502,82 +502,82 @@ public void SetCombineAsync_2() ...@@ -502,82 +502,82 @@ public void SetCombineAsync_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.SetCombineAsync(SetOperation.Intersect, keys, CommandFlags.HighPriority); wrapper.SetCombineAsync(SetOperation.Intersect, keys, CommandFlags.None);
mock.Verify(_ => _.SetCombineAsync(SetOperation.Intersect, It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SetCombineAsync(SetOperation.Intersect, It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void SetContainsAsync() public void SetContainsAsync()
{ {
wrapper.SetContainsAsync("key", "value", CommandFlags.HighPriority); wrapper.SetContainsAsync("key", "value", CommandFlags.None);
mock.Verify(_ => _.SetContainsAsync("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.SetContainsAsync("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void SetLengthAsync() public void SetLengthAsync()
{ {
wrapper.SetLengthAsync("key", CommandFlags.HighPriority); wrapper.SetLengthAsync("key", CommandFlags.None);
mock.Verify(_ => _.SetLengthAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.SetLengthAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void SetMembersAsync() public void SetMembersAsync()
{ {
wrapper.SetMembersAsync("key", CommandFlags.HighPriority); wrapper.SetMembersAsync("key", CommandFlags.None);
mock.Verify(_ => _.SetMembersAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.SetMembersAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void SetMoveAsync() public void SetMoveAsync()
{ {
wrapper.SetMoveAsync("source", "destination", "value", CommandFlags.HighPriority); wrapper.SetMoveAsync("source", "destination", "value", CommandFlags.None);
mock.Verify(_ => _.SetMoveAsync("prefix:source", "prefix:destination", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.SetMoveAsync("prefix:source", "prefix:destination", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void SetPopAsync_1() public void SetPopAsync_1()
{ {
wrapper.SetPopAsync("key", CommandFlags.HighPriority); wrapper.SetPopAsync("key", CommandFlags.None);
mock.Verify(_ => _.SetPopAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.SetPopAsync("prefix:key", CommandFlags.None));
wrapper.SetPopAsync("key", 5, CommandFlags.HighPriority); wrapper.SetPopAsync("key", 5, CommandFlags.None);
mock.Verify(_ => _.SetPopAsync("prefix:key", 5, CommandFlags.HighPriority)); mock.Verify(_ => _.SetPopAsync("prefix:key", 5, CommandFlags.None));
} }
[Fact] [Fact]
public void SetPopAsync_2() public void SetPopAsync_2()
{ {
wrapper.SetPopAsync("key", 5, CommandFlags.HighPriority); wrapper.SetPopAsync("key", 5, CommandFlags.None);
mock.Verify(_ => _.SetPopAsync("prefix:key", 5, CommandFlags.HighPriority)); mock.Verify(_ => _.SetPopAsync("prefix:key", 5, CommandFlags.None));
} }
[Fact] [Fact]
public void SetRandomMemberAsync() public void SetRandomMemberAsync()
{ {
wrapper.SetRandomMemberAsync("key", CommandFlags.HighPriority); wrapper.SetRandomMemberAsync("key", CommandFlags.None);
mock.Verify(_ => _.SetRandomMemberAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.SetRandomMemberAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void SetRandomMembersAsync() public void SetRandomMembersAsync()
{ {
wrapper.SetRandomMembersAsync("key", 123, CommandFlags.HighPriority); wrapper.SetRandomMembersAsync("key", 123, CommandFlags.None);
mock.Verify(_ => _.SetRandomMembersAsync("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.SetRandomMembersAsync("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void SetRemoveAsync_1() public void SetRemoveAsync_1()
{ {
wrapper.SetRemoveAsync("key", "value", CommandFlags.HighPriority); wrapper.SetRemoveAsync("key", "value", CommandFlags.None);
mock.Verify(_ => _.SetRemoveAsync("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.SetRemoveAsync("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void SetRemoveAsync_2() public void SetRemoveAsync_2()
{ {
RedisValue[] values = new RedisValue[0]; RedisValue[] values = new RedisValue[0];
wrapper.SetRemoveAsync("key", values, CommandFlags.HighPriority); wrapper.SetRemoveAsync("key", values, CommandFlags.None);
mock.Verify(_ => _.SetRemoveAsync("prefix:key", values, CommandFlags.HighPriority)); mock.Verify(_ => _.SetRemoveAsync("prefix:key", values, CommandFlags.None));
} }
[Fact] [Fact]
...@@ -586,11 +586,11 @@ public void SortAndStoreAsync() ...@@ -586,11 +586,11 @@ public void SortAndStoreAsync()
RedisValue[] get = new RedisValue[] { "a", "#" }; RedisValue[] get = new RedisValue[] { "a", "#" };
Expression<Func<RedisValue[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "#"; Expression<Func<RedisValue[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "#";
wrapper.SortAndStoreAsync("destination", "key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", get, CommandFlags.HighPriority); wrapper.SortAndStoreAsync("destination", "key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", get, CommandFlags.None);
wrapper.SortAndStoreAsync("destination", "key", 123, 456, Order.Descending, SortType.Alphabetic, "by", get, CommandFlags.HighPriority); wrapper.SortAndStoreAsync("destination", "key", 123, 456, Order.Descending, SortType.Alphabetic, "by", get, CommandFlags.None);
mock.Verify(_ => _.SortAndStoreAsync("prefix:destination", "prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SortAndStoreAsync("prefix:destination", "prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", It.Is(valid), CommandFlags.None));
mock.Verify(_ => _.SortAndStoreAsync("prefix:destination", "prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "prefix:by", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SortAndStoreAsync("prefix:destination", "prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "prefix:by", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
...@@ -599,33 +599,33 @@ public void SortAsync() ...@@ -599,33 +599,33 @@ public void SortAsync()
RedisValue[] get = new RedisValue[] { "a", "#" }; RedisValue[] get = new RedisValue[] { "a", "#" };
Expression<Func<RedisValue[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "#"; Expression<Func<RedisValue[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "#";
wrapper.SortAsync("key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", get, CommandFlags.HighPriority); wrapper.SortAsync("key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", get, CommandFlags.None);
wrapper.SortAsync("key", 123, 456, Order.Descending, SortType.Alphabetic, "by", get, CommandFlags.HighPriority); wrapper.SortAsync("key", 123, 456, Order.Descending, SortType.Alphabetic, "by", get, CommandFlags.None);
mock.Verify(_ => _.SortAsync("prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SortAsync("prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "nosort", It.Is(valid), CommandFlags.None));
mock.Verify(_ => _.SortAsync("prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "prefix:by", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SortAsync("prefix:key", 123, 456, Order.Descending, SortType.Alphabetic, "prefix:by", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetAddAsync_1() public void SortedSetAddAsync_1()
{ {
wrapper.SortedSetAddAsync("key", "member", 1.23, When.Exists, CommandFlags.HighPriority); wrapper.SortedSetAddAsync("key", "member", 1.23, When.Exists, CommandFlags.None);
mock.Verify(_ => _.SortedSetAddAsync("prefix:key", "member", 1.23, When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetAddAsync("prefix:key", "member", 1.23, When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetAddAsync_2() public void SortedSetAddAsync_2()
{ {
SortedSetEntry[] values = new SortedSetEntry[0]; SortedSetEntry[] values = new SortedSetEntry[0];
wrapper.SortedSetAddAsync("key", values, When.Exists, CommandFlags.HighPriority); wrapper.SortedSetAddAsync("key", values, When.Exists, CommandFlags.None);
mock.Verify(_ => _.SortedSetAddAsync("prefix:key", values, When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetAddAsync("prefix:key", values, When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetCombineAndStoreAsync_1() public void SortedSetCombineAndStoreAsync_1()
{ {
wrapper.SortedSetCombineAndStoreAsync(SetOperation.Intersect, "destination", "first", "second", Aggregate.Max, CommandFlags.HighPriority); wrapper.SortedSetCombineAndStoreAsync(SetOperation.Intersect, "destination", "first", "second", Aggregate.Max, CommandFlags.None);
mock.Verify(_ => _.SortedSetCombineAndStoreAsync(SetOperation.Intersect, "prefix:destination", "prefix:first", "prefix:second", Aggregate.Max, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetCombineAndStoreAsync(SetOperation.Intersect, "prefix:destination", "prefix:first", "prefix:second", Aggregate.Max, CommandFlags.None));
} }
[Fact] [Fact]
...@@ -633,317 +633,317 @@ public void SortedSetCombineAndStoreAsync_2() ...@@ -633,317 +633,317 @@ public void SortedSetCombineAndStoreAsync_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.SetCombineAndStoreAsync(SetOperation.Intersect, "destination", keys, CommandFlags.HighPriority); wrapper.SetCombineAndStoreAsync(SetOperation.Intersect, "destination", keys, CommandFlags.None);
mock.Verify(_ => _.SetCombineAndStoreAsync(SetOperation.Intersect, "prefix:destination", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.SetCombineAndStoreAsync(SetOperation.Intersect, "prefix:destination", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetDecrementAsync() public void SortedSetDecrementAsync()
{ {
wrapper.SortedSetDecrementAsync("key", "member", 1.23, CommandFlags.HighPriority); wrapper.SortedSetDecrementAsync("key", "member", 1.23, CommandFlags.None);
mock.Verify(_ => _.SortedSetDecrementAsync("prefix:key", "member", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetDecrementAsync("prefix:key", "member", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetIncrementAsync() public void SortedSetIncrementAsync()
{ {
wrapper.SortedSetIncrementAsync("key", "member", 1.23, CommandFlags.HighPriority); wrapper.SortedSetIncrementAsync("key", "member", 1.23, CommandFlags.None);
mock.Verify(_ => _.SortedSetIncrementAsync("prefix:key", "member", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetIncrementAsync("prefix:key", "member", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetLengthAsync() public void SortedSetLengthAsync()
{ {
wrapper.SortedSetLengthAsync("key", 1.23, 1.23, Exclude.Start, CommandFlags.HighPriority); wrapper.SortedSetLengthAsync("key", 1.23, 1.23, Exclude.Start, CommandFlags.None);
mock.Verify(_ => _.SortedSetLengthAsync("prefix:key", 1.23, 1.23, Exclude.Start, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetLengthAsync("prefix:key", 1.23, 1.23, Exclude.Start, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetLengthByValueAsync() public void SortedSetLengthByValueAsync()
{ {
wrapper.SortedSetLengthByValueAsync("key", "min", "max", Exclude.Start, CommandFlags.HighPriority); wrapper.SortedSetLengthByValueAsync("key", "min", "max", Exclude.Start, CommandFlags.None);
mock.Verify(_ => _.SortedSetLengthByValueAsync("prefix:key", "min", "max", Exclude.Start, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetLengthByValueAsync("prefix:key", "min", "max", Exclude.Start, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByRankAsync() public void SortedSetRangeByRankAsync()
{ {
wrapper.SortedSetRangeByRankAsync("key", 123, 456, Order.Descending, CommandFlags.HighPriority); wrapper.SortedSetRangeByRankAsync("key", 123, 456, Order.Descending, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByRankAsync("prefix:key", 123, 456, Order.Descending, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByRankAsync("prefix:key", 123, 456, Order.Descending, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByRankWithScoresAsync() public void SortedSetRangeByRankWithScoresAsync()
{ {
wrapper.SortedSetRangeByRankWithScoresAsync("key", 123, 456, Order.Descending, CommandFlags.HighPriority); wrapper.SortedSetRangeByRankWithScoresAsync("key", 123, 456, Order.Descending, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByRankWithScoresAsync("prefix:key", 123, 456, Order.Descending, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByRankWithScoresAsync("prefix:key", 123, 456, Order.Descending, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByScoreAsync() public void SortedSetRangeByScoreAsync()
{ {
wrapper.SortedSetRangeByScoreAsync("key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority); wrapper.SortedSetRangeByScoreAsync("key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByScoreAsync("prefix:key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByScoreAsync("prefix:key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByScoreWithScoresAsync() public void SortedSetRangeByScoreWithScoresAsync()
{ {
wrapper.SortedSetRangeByScoreWithScoresAsync("key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority); wrapper.SortedSetRangeByScoreWithScoresAsync("key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByScoreWithScoresAsync("prefix:key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByScoreWithScoresAsync("prefix:key", 1.23, 1.23, Exclude.Start, Order.Descending, 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByValueAsync() public void SortedSetRangeByValueAsync()
{ {
wrapper.SortedSetRangeByValueAsync("key", "min", "max", Exclude.Start, 123, 456, CommandFlags.HighPriority); wrapper.SortedSetRangeByValueAsync("key", "min", "max", Exclude.Start, 123, 456, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByValueAsync("prefix:key", "min", "max", Exclude.Start, Order.Ascending, 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByValueAsync("prefix:key", "min", "max", Exclude.Start, Order.Ascending, 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRangeByValueDescAsync() public void SortedSetRangeByValueDescAsync()
{ {
wrapper.SortedSetRangeByValueAsync("key", "min", "max", Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority); wrapper.SortedSetRangeByValueAsync("key", "min", "max", Exclude.Start, Order.Descending, 123, 456, CommandFlags.None);
mock.Verify(_ => _.SortedSetRangeByValueAsync("prefix:key", "min", "max", Exclude.Start, Order.Descending, 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRangeByValueAsync("prefix:key", "min", "max", Exclude.Start, Order.Descending, 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRankAsync() public void SortedSetRankAsync()
{ {
wrapper.SortedSetRankAsync("key", "member", Order.Descending, CommandFlags.HighPriority); wrapper.SortedSetRankAsync("key", "member", Order.Descending, CommandFlags.None);
mock.Verify(_ => _.SortedSetRankAsync("prefix:key", "member", Order.Descending, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRankAsync("prefix:key", "member", Order.Descending, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRemoveAsync_1() public void SortedSetRemoveAsync_1()
{ {
wrapper.SortedSetRemoveAsync("key", "member", CommandFlags.HighPriority); wrapper.SortedSetRemoveAsync("key", "member", CommandFlags.None);
mock.Verify(_ => _.SortedSetRemoveAsync("prefix:key", "member", CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRemoveAsync("prefix:key", "member", CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRemoveAsync_2() public void SortedSetRemoveAsync_2()
{ {
RedisValue[] members = new RedisValue[0]; RedisValue[] members = new RedisValue[0];
wrapper.SortedSetRemoveAsync("key", members, CommandFlags.HighPriority); wrapper.SortedSetRemoveAsync("key", members, CommandFlags.None);
mock.Verify(_ => _.SortedSetRemoveAsync("prefix:key", members, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRemoveAsync("prefix:key", members, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRemoveRangeByRankAsync() public void SortedSetRemoveRangeByRankAsync()
{ {
wrapper.SortedSetRemoveRangeByRankAsync("key", 123, 456, CommandFlags.HighPriority); wrapper.SortedSetRemoveRangeByRankAsync("key", 123, 456, CommandFlags.None);
mock.Verify(_ => _.SortedSetRemoveRangeByRankAsync("prefix:key", 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRemoveRangeByRankAsync("prefix:key", 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRemoveRangeByScoreAsync() public void SortedSetRemoveRangeByScoreAsync()
{ {
wrapper.SortedSetRemoveRangeByScoreAsync("key", 1.23, 1.23, Exclude.Start, CommandFlags.HighPriority); wrapper.SortedSetRemoveRangeByScoreAsync("key", 1.23, 1.23, Exclude.Start, CommandFlags.None);
mock.Verify(_ => _.SortedSetRemoveRangeByScoreAsync("prefix:key", 1.23, 1.23, Exclude.Start, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRemoveRangeByScoreAsync("prefix:key", 1.23, 1.23, Exclude.Start, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetRemoveRangeByValueAsync() public void SortedSetRemoveRangeByValueAsync()
{ {
wrapper.SortedSetRemoveRangeByValueAsync("key", "min", "max", Exclude.Start, CommandFlags.HighPriority); wrapper.SortedSetRemoveRangeByValueAsync("key", "min", "max", Exclude.Start, CommandFlags.None);
mock.Verify(_ => _.SortedSetRemoveRangeByValueAsync("prefix:key", "min", "max", Exclude.Start, CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetRemoveRangeByValueAsync("prefix:key", "min", "max", Exclude.Start, CommandFlags.None));
} }
[Fact] [Fact]
public void SortedSetScoreAsync() public void SortedSetScoreAsync()
{ {
wrapper.SortedSetScoreAsync("key", "member", CommandFlags.HighPriority); wrapper.SortedSetScoreAsync("key", "member", CommandFlags.None);
mock.Verify(_ => _.SortedSetScoreAsync("prefix:key", "member", CommandFlags.HighPriority)); mock.Verify(_ => _.SortedSetScoreAsync("prefix:key", "member", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamAcknowledgeAsync_1() public void StreamAcknowledgeAsync_1()
{ {
wrapper.StreamAcknowledgeAsync("key", "group", "0-0", CommandFlags.HighPriority); wrapper.StreamAcknowledgeAsync("key", "group", "0-0", CommandFlags.None);
mock.Verify(_ => _.StreamAcknowledgeAsync("prefix:key", "group", "0-0", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamAcknowledgeAsync("prefix:key", "group", "0-0", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamAcknowledgeAsync_2() public void StreamAcknowledgeAsync_2()
{ {
var messageIds = new RedisValue[] { "0-0", "0-1", "0-2" }; var messageIds = new RedisValue[] { "0-0", "0-1", "0-2" };
wrapper.StreamAcknowledgeAsync("key", "group", messageIds, CommandFlags.HighPriority); wrapper.StreamAcknowledgeAsync("key", "group", messageIds, CommandFlags.None);
mock.Verify(_ => _.StreamAcknowledgeAsync("prefix:key", "group", messageIds, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamAcknowledgeAsync("prefix:key", "group", messageIds, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamAddAsync_1() public void StreamAddAsync_1()
{ {
wrapper.StreamAddAsync("key", "field1", "value1", "*", 1000, true, CommandFlags.HighPriority); wrapper.StreamAddAsync("key", "field1", "value1", "*", 1000, true, CommandFlags.None);
mock.Verify(_ => _.StreamAddAsync("prefix:key", "field1", "value1", "*", 1000, true, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamAddAsync("prefix:key", "field1", "value1", "*", 1000, true, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamAddAsync_2() public void StreamAddAsync_2()
{ {
var fields = new NameValueEntry[0]; var fields = new NameValueEntry[0];
wrapper.StreamAddAsync("key", fields, "*", 1000, true, CommandFlags.HighPriority); wrapper.StreamAddAsync("key", fields, "*", 1000, true, CommandFlags.None);
mock.Verify(_ => _.StreamAddAsync("prefix:key", fields, "*", 1000, true, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamAddAsync("prefix:key", fields, "*", 1000, true, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamClaimMessagesAsync() public void StreamClaimMessagesAsync()
{ {
var messageIds = new RedisValue[0]; var messageIds = new RedisValue[0];
wrapper.StreamClaimAsync("key", "group", "consumer", 1000, messageIds, CommandFlags.HighPriority); wrapper.StreamClaimAsync("key", "group", "consumer", 1000, messageIds, CommandFlags.None);
mock.Verify(_ => _.StreamClaimAsync("prefix:key", "group", "consumer", 1000, messageIds, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamClaimAsync("prefix:key", "group", "consumer", 1000, messageIds, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamClaimMessagesReturningIdsAsync() public void StreamClaimMessagesReturningIdsAsync()
{ {
var messageIds = new RedisValue[0]; var messageIds = new RedisValue[0];
wrapper.StreamClaimIdsOnlyAsync("key", "group", "consumer", 1000, messageIds, CommandFlags.HighPriority); wrapper.StreamClaimIdsOnlyAsync("key", "group", "consumer", 1000, messageIds, CommandFlags.None);
mock.Verify(_ => _.StreamClaimIdsOnlyAsync("prefix:key", "group", "consumer", 1000, messageIds, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamClaimIdsOnlyAsync("prefix:key", "group", "consumer", 1000, messageIds, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamConsumerInfoGetAsync() public void StreamConsumerInfoGetAsync()
{ {
wrapper.StreamConsumerInfoAsync("key", "group", CommandFlags.HighPriority); wrapper.StreamConsumerInfoAsync("key", "group", CommandFlags.None);
mock.Verify(_ => _.StreamConsumerInfoAsync("prefix:key", "group", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamConsumerInfoAsync("prefix:key", "group", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamConsumerGroupSetPositionAsync() public void StreamConsumerGroupSetPositionAsync()
{ {
wrapper.StreamConsumerGroupSetPositionAsync("key", "group", StreamPosition.Beginning, CommandFlags.HighPriority); wrapper.StreamConsumerGroupSetPositionAsync("key", "group", StreamPosition.Beginning, CommandFlags.None);
mock.Verify(_ => _.StreamConsumerGroupSetPositionAsync("prefix:key", "group", StreamPosition.Beginning, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamConsumerGroupSetPositionAsync("prefix:key", "group", StreamPosition.Beginning, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamCreateConsumerGroupAsync() public void StreamCreateConsumerGroupAsync()
{ {
wrapper.StreamCreateConsumerGroupAsync("key", "group", "0-0", CommandFlags.HighPriority); wrapper.StreamCreateConsumerGroupAsync("key", "group", "0-0", CommandFlags.None);
mock.Verify(_ => _.StreamCreateConsumerGroupAsync("prefix:key", "group", "0-0", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamCreateConsumerGroupAsync("prefix:key", "group", "0-0", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamGroupInfoGetAsync() public void StreamGroupInfoGetAsync()
{ {
wrapper.StreamGroupInfoAsync("key", CommandFlags.HighPriority); wrapper.StreamGroupInfoAsync("key", CommandFlags.None);
mock.Verify(_ => _.StreamGroupInfoAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamGroupInfoAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamInfoGetAsync() public void StreamInfoGetAsync()
{ {
wrapper.StreamInfoAsync("key", CommandFlags.HighPriority); wrapper.StreamInfoAsync("key", CommandFlags.None);
mock.Verify(_ => _.StreamInfoAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamInfoAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamLengthAsync() public void StreamLengthAsync()
{ {
wrapper.StreamLengthAsync("key", CommandFlags.HighPriority); wrapper.StreamLengthAsync("key", CommandFlags.None);
mock.Verify(_ => _.StreamLengthAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamLengthAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamMessagesDeleteAsync() public void StreamMessagesDeleteAsync()
{ {
var messageIds = new RedisValue[0] { }; var messageIds = new RedisValue[0] { };
wrapper.StreamDeleteAsync("key", messageIds, CommandFlags.HighPriority); wrapper.StreamDeleteAsync("key", messageIds, CommandFlags.None);
mock.Verify(_ => _.StreamDeleteAsync("prefix:key", messageIds, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamDeleteAsync("prefix:key", messageIds, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamDeleteConsumerAsync() public void StreamDeleteConsumerAsync()
{ {
wrapper.StreamDeleteConsumerAsync("key", "group", "consumer", CommandFlags.HighPriority); wrapper.StreamDeleteConsumerAsync("key", "group", "consumer", CommandFlags.None);
mock.Verify(_ => _.StreamDeleteConsumerAsync("prefix:key", "group", "consumer", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamDeleteConsumerAsync("prefix:key", "group", "consumer", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamDeleteConsumerGroupAsync() public void StreamDeleteConsumerGroupAsync()
{ {
wrapper.StreamDeleteConsumerGroupAsync("key", "group", CommandFlags.HighPriority); wrapper.StreamDeleteConsumerGroupAsync("key", "group", CommandFlags.None);
mock.Verify(_ => _.StreamDeleteConsumerGroupAsync("prefix:key", "group", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamDeleteConsumerGroupAsync("prefix:key", "group", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamPendingInfoGetAsync() public void StreamPendingInfoGetAsync()
{ {
wrapper.StreamPendingAsync("key", "group", CommandFlags.HighPriority); wrapper.StreamPendingAsync("key", "group", CommandFlags.None);
mock.Verify(_ => _.StreamPendingAsync("prefix:key", "group", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamPendingAsync("prefix:key", "group", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamPendingMessageInfoGetAsync() public void StreamPendingMessageInfoGetAsync()
{ {
wrapper.StreamPendingMessagesAsync("key", "group", 10, RedisValue.Null, "-", "+", CommandFlags.HighPriority); wrapper.StreamPendingMessagesAsync("key", "group", 10, RedisValue.Null, "-", "+", CommandFlags.None);
mock.Verify(_ => _.StreamPendingMessagesAsync("prefix:key", "group", 10, RedisValue.Null, "-", "+", CommandFlags.HighPriority)); mock.Verify(_ => _.StreamPendingMessagesAsync("prefix:key", "group", 10, RedisValue.Null, "-", "+", CommandFlags.None));
} }
[Fact] [Fact]
public void StreamRangeAsync() public void StreamRangeAsync()
{ {
wrapper.StreamRangeAsync("key", "-", "+", null, Order.Ascending, CommandFlags.HighPriority); wrapper.StreamRangeAsync("key", "-", "+", null, Order.Ascending, CommandFlags.None);
mock.Verify(_ => _.StreamRangeAsync("prefix:key", "-", "+", null, Order.Ascending, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamRangeAsync("prefix:key", "-", "+", null, Order.Ascending, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamReadAsync_1() public void StreamReadAsync_1()
{ {
var streamPositions = new StreamPosition[0] { }; var streamPositions = new StreamPosition[0] { };
wrapper.StreamReadAsync(streamPositions, null, CommandFlags.HighPriority); wrapper.StreamReadAsync(streamPositions, null, CommandFlags.None);
mock.Verify(_ => _.StreamReadAsync(streamPositions, null, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamReadAsync(streamPositions, null, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamReadAsync_2() public void StreamReadAsync_2()
{ {
wrapper.StreamReadAsync("key", "0-0", null, CommandFlags.HighPriority); wrapper.StreamReadAsync("key", "0-0", null, CommandFlags.None);
mock.Verify(_ => _.StreamReadAsync("prefix:key", "0-0", null, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamReadAsync("prefix:key", "0-0", null, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamReadGroupAsync_1() public void StreamReadGroupAsync_1()
{ {
wrapper.StreamReadGroupAsync("key", "group", "consumer", StreamPosition.Beginning, 10, CommandFlags.HighPriority); wrapper.StreamReadGroupAsync("key", "group", "consumer", StreamPosition.Beginning, 10, CommandFlags.None);
mock.Verify(_ => _.StreamReadGroupAsync("prefix:key", "group", "consumer", StreamPosition.Beginning, 10, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamReadGroupAsync("prefix:key", "group", "consumer", StreamPosition.Beginning, 10, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamStreamReadGroupAsync_2() public void StreamStreamReadGroupAsync_2()
{ {
var streamPositions = new StreamPosition[0] { }; var streamPositions = new StreamPosition[0] { };
wrapper.StreamReadGroupAsync(streamPositions, "group", "consumer", 10, CommandFlags.HighPriority); wrapper.StreamReadGroupAsync(streamPositions, "group", "consumer", 10, CommandFlags.None);
mock.Verify(_ => _.StreamReadGroupAsync(streamPositions, "group", "consumer", 10, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamReadGroupAsync(streamPositions, "group", "consumer", 10, CommandFlags.None));
} }
[Fact] [Fact]
public void StreamTrimAsync() public void StreamTrimAsync()
{ {
wrapper.StreamTrimAsync("key", 1000, true, CommandFlags.HighPriority); wrapper.StreamTrimAsync("key", 1000, true, CommandFlags.None);
mock.Verify(_ => _.StreamTrimAsync("prefix:key", 1000, true, CommandFlags.HighPriority)); mock.Verify(_ => _.StreamTrimAsync("prefix:key", 1000, true, CommandFlags.None));
} }
[Fact] [Fact]
public void StringAppendAsync() public void StringAppendAsync()
{ {
wrapper.StringAppendAsync("key", "value", CommandFlags.HighPriority); wrapper.StringAppendAsync("key", "value", CommandFlags.None);
mock.Verify(_ => _.StringAppendAsync("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.StringAppendAsync("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void StringBitCountAsync() public void StringBitCountAsync()
{ {
wrapper.StringBitCountAsync("key", 123, 456, CommandFlags.HighPriority); wrapper.StringBitCountAsync("key", 123, 456, CommandFlags.None);
mock.Verify(_ => _.StringBitCountAsync("prefix:key", 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.StringBitCountAsync("prefix:key", 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void StringBitOperationAsync_1() public void StringBitOperationAsync_1()
{ {
wrapper.StringBitOperationAsync(Bitwise.Xor, "destination", "first", "second", CommandFlags.HighPriority); wrapper.StringBitOperationAsync(Bitwise.Xor, "destination", "first", "second", CommandFlags.None);
mock.Verify(_ => _.StringBitOperationAsync(Bitwise.Xor, "prefix:destination", "prefix:first", "prefix:second", CommandFlags.HighPriority)); mock.Verify(_ => _.StringBitOperationAsync(Bitwise.Xor, "prefix:destination", "prefix:first", "prefix:second", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -951,36 +951,36 @@ public void StringBitOperationAsync_2() ...@@ -951,36 +951,36 @@ public void StringBitOperationAsync_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.StringBitOperationAsync(Bitwise.Xor, "destination", keys, CommandFlags.HighPriority); wrapper.StringBitOperationAsync(Bitwise.Xor, "destination", keys, CommandFlags.None);
mock.Verify(_ => _.StringBitOperationAsync(Bitwise.Xor, "prefix:destination", It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.StringBitOperationAsync(Bitwise.Xor, "prefix:destination", It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void StringBitPositionAsync() public void StringBitPositionAsync()
{ {
wrapper.StringBitPositionAsync("key", true, 123, 456, CommandFlags.HighPriority); wrapper.StringBitPositionAsync("key", true, 123, 456, CommandFlags.None);
mock.Verify(_ => _.StringBitPositionAsync("prefix:key", true, 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.StringBitPositionAsync("prefix:key", true, 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void StringDecrementAsync_1() public void StringDecrementAsync_1()
{ {
wrapper.StringDecrementAsync("key", 123, CommandFlags.HighPriority); wrapper.StringDecrementAsync("key", 123, CommandFlags.None);
mock.Verify(_ => _.StringDecrementAsync("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.StringDecrementAsync("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void StringDecrementAsync_2() public void StringDecrementAsync_2()
{ {
wrapper.StringDecrementAsync("key", 1.23, CommandFlags.HighPriority); wrapper.StringDecrementAsync("key", 1.23, CommandFlags.None);
mock.Verify(_ => _.StringDecrementAsync("prefix:key", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.StringDecrementAsync("prefix:key", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void StringGetAsync_1() public void StringGetAsync_1()
{ {
wrapper.StringGetAsync("key", CommandFlags.HighPriority); wrapper.StringGetAsync("key", CommandFlags.None);
mock.Verify(_ => _.StringGetAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StringGetAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
...@@ -988,65 +988,65 @@ public void StringGetAsync_2() ...@@ -988,65 +988,65 @@ public void StringGetAsync_2()
{ {
RedisKey[] keys = new RedisKey[] { "a", "b" }; RedisKey[] keys = new RedisKey[] { "a", "b" };
Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b"; Expression<Func<RedisKey[], bool>> valid = _ => _.Length == 2 && _[0] == "prefix:a" && _[1] == "prefix:b";
wrapper.StringGetAsync(keys, CommandFlags.HighPriority); wrapper.StringGetAsync(keys, CommandFlags.None);
mock.Verify(_ => _.StringGetAsync(It.Is(valid), CommandFlags.HighPriority)); mock.Verify(_ => _.StringGetAsync(It.Is(valid), CommandFlags.None));
} }
[Fact] [Fact]
public void StringGetBitAsync() public void StringGetBitAsync()
{ {
wrapper.StringGetBitAsync("key", 123, CommandFlags.HighPriority); wrapper.StringGetBitAsync("key", 123, CommandFlags.None);
mock.Verify(_ => _.StringGetBitAsync("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.StringGetBitAsync("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void StringGetRangeAsync() public void StringGetRangeAsync()
{ {
wrapper.StringGetRangeAsync("key", 123, 456, CommandFlags.HighPriority); wrapper.StringGetRangeAsync("key", 123, 456, CommandFlags.None);
mock.Verify(_ => _.StringGetRangeAsync("prefix:key", 123, 456, CommandFlags.HighPriority)); mock.Verify(_ => _.StringGetRangeAsync("prefix:key", 123, 456, CommandFlags.None));
} }
[Fact] [Fact]
public void StringGetSetAsync() public void StringGetSetAsync()
{ {
wrapper.StringGetSetAsync("key", "value", CommandFlags.HighPriority); wrapper.StringGetSetAsync("key", "value", CommandFlags.None);
mock.Verify(_ => _.StringGetSetAsync("prefix:key", "value", CommandFlags.HighPriority)); mock.Verify(_ => _.StringGetSetAsync("prefix:key", "value", CommandFlags.None));
} }
[Fact] [Fact]
public void StringGetWithExpiryAsync() public void StringGetWithExpiryAsync()
{ {
wrapper.StringGetWithExpiryAsync("key", CommandFlags.HighPriority); wrapper.StringGetWithExpiryAsync("key", CommandFlags.None);
mock.Verify(_ => _.StringGetWithExpiryAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StringGetWithExpiryAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void StringIncrementAsync_1() public void StringIncrementAsync_1()
{ {
wrapper.StringIncrementAsync("key", 123, CommandFlags.HighPriority); wrapper.StringIncrementAsync("key", 123, CommandFlags.None);
mock.Verify(_ => _.StringIncrementAsync("prefix:key", 123, CommandFlags.HighPriority)); mock.Verify(_ => _.StringIncrementAsync("prefix:key", 123, CommandFlags.None));
} }
[Fact] [Fact]
public void StringIncrementAsync_2() public void StringIncrementAsync_2()
{ {
wrapper.StringIncrementAsync("key", 1.23, CommandFlags.HighPriority); wrapper.StringIncrementAsync("key", 1.23, CommandFlags.None);
mock.Verify(_ => _.StringIncrementAsync("prefix:key", 1.23, CommandFlags.HighPriority)); mock.Verify(_ => _.StringIncrementAsync("prefix:key", 1.23, CommandFlags.None));
} }
[Fact] [Fact]
public void StringLengthAsync() public void StringLengthAsync()
{ {
wrapper.StringLengthAsync("key", CommandFlags.HighPriority); wrapper.StringLengthAsync("key", CommandFlags.None);
mock.Verify(_ => _.StringLengthAsync("prefix:key", CommandFlags.HighPriority)); mock.Verify(_ => _.StringLengthAsync("prefix:key", CommandFlags.None));
} }
[Fact] [Fact]
public void StringSetAsync_1() public void StringSetAsync_1()
{ {
TimeSpan expiry = TimeSpan.FromSeconds(123); TimeSpan expiry = TimeSpan.FromSeconds(123);
wrapper.StringSetAsync("key", "value", expiry, When.Exists, CommandFlags.HighPriority); wrapper.StringSetAsync("key", "value", expiry, When.Exists, CommandFlags.None);
mock.Verify(_ => _.StringSetAsync("prefix:key", "value", expiry, When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.StringSetAsync("prefix:key", "value", expiry, When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
...@@ -1054,22 +1054,22 @@ public void StringSetAsync_2() ...@@ -1054,22 +1054,22 @@ public void StringSetAsync_2()
{ {
KeyValuePair<RedisKey, RedisValue>[] values = new KeyValuePair<RedisKey, RedisValue>[] { new KeyValuePair<RedisKey, RedisValue>("a", "x"), new KeyValuePair<RedisKey, RedisValue>("b", "y") }; KeyValuePair<RedisKey, RedisValue>[] values = new KeyValuePair<RedisKey, RedisValue>[] { new KeyValuePair<RedisKey, RedisValue>("a", "x"), new KeyValuePair<RedisKey, RedisValue>("b", "y") };
Expression<Func<KeyValuePair<RedisKey, RedisValue>[], bool>> valid = _ => _.Length == 2 && _[0].Key == "prefix:a" && _[0].Value == "x" && _[1].Key == "prefix:b" && _[1].Value == "y"; Expression<Func<KeyValuePair<RedisKey, RedisValue>[], bool>> valid = _ => _.Length == 2 && _[0].Key == "prefix:a" && _[0].Value == "x" && _[1].Key == "prefix:b" && _[1].Value == "y";
wrapper.StringSetAsync(values, When.Exists, CommandFlags.HighPriority); wrapper.StringSetAsync(values, When.Exists, CommandFlags.None);
mock.Verify(_ => _.StringSetAsync(It.Is(valid), When.Exists, CommandFlags.HighPriority)); mock.Verify(_ => _.StringSetAsync(It.Is(valid), When.Exists, CommandFlags.None));
} }
[Fact] [Fact]
public void StringSetBitAsync() public void StringSetBitAsync()
{ {
wrapper.StringSetBitAsync("key", 123, true, CommandFlags.HighPriority); wrapper.StringSetBitAsync("key", 123, true, CommandFlags.None);
mock.Verify(_ => _.StringSetBitAsync("prefix:key", 123, true, CommandFlags.HighPriority)); mock.Verify(_ => _.StringSetBitAsync("prefix:key", 123, true, CommandFlags.None));
} }
[Fact] [Fact]
public void StringSetRangeAsync() public void StringSetRangeAsync()
{ {
wrapper.StringSetRangeAsync("key", 123, "value", CommandFlags.HighPriority); wrapper.StringSetRangeAsync("key", 123, "value", CommandFlags.None);
mock.Verify(_ => _.StringSetRangeAsync("prefix:key", 123, "value", CommandFlags.HighPriority)); mock.Verify(_ => _.StringSetRangeAsync("prefix:key", 123, "value", CommandFlags.None));
} }
#pragma warning restore RCS1047 // Non-asynchronous method name should not end with 'Async'. #pragma warning restore RCS1047 // Non-asynchronous method name should not end with 'Async'.
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment