File tree Expand file tree Collapse file tree 1 file changed +0
-27
lines changed
test/RedisSessionStateProviderFunctionalTests Expand file tree Collapse file tree 1 file changed +0
-27
lines changed Original file line number Diff line number Diff line change @@ -772,33 +772,6 @@ public void TryUpdateAndReleaseLockIfLockIdMatch_LargeLockTime_ExpireManuallyTes
772772 }
773773 }
774774
775- [ Fact ]
776- public void TestingForceReconnect ( )
777- {
778- ProviderConfiguration pc = Utility . GetDefaultConfigUtility ( ) ;
779- using ( RedisServer redisServer = new RedisServer ( ) )
780- {
781- RedisSharedConnection . ReconnectFrequency = TimeSpan . FromMilliseconds ( 5 ) ;
782- RedisConnectionWrapper redisConn = GetRedisConnectionWrapperWithUniqueSession ( ) ;
783-
784- DateTimeOffset first_lastReconnectTime = RedisSharedConnection . lastReconnectTime ;
785- // Inserting data into redis server
786- ChangeTrackingSessionStateItemCollection data = new ChangeTrackingSessionStateItemCollection ( new RedisUtility ( pc ) ) ;
787- data [ "key" ] = "value" ;
788- redisConn . Set ( data , 900 ) ;
789- Assert . Equal ( first_lastReconnectTime , RedisSharedConnection . lastReconnectTime ) ;
790- System . Threading . Thread . Sleep ( 6 ) ;
791-
792- //This should cause RedisConnectionException
793- redisServer . Restart ( ) ;
794- redisConn . UpdateExpiryTime ( 900 ) ;
795-
796- // This proves that force reconnect happened
797- Assert . NotEqual ( first_lastReconnectTime , RedisSharedConnection . lastReconnectTime ) ;
798- DisposeRedisConnectionWrapper ( redisConn ) ;
799- }
800- }
801-
802775 private IDatabase GetRealRedisConnection ( RedisConnectionWrapper redisConn )
803776 {
804777 return ( IDatabase ) ( ( StackExchangeClientConnection ) redisConn . redisConnection ) . RealConnection ;
You can’t perform that action at this time.
0 commit comments