File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed
Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -21,17 +21,15 @@ struct TestConnection {
2121 connection : Connection ,
2222}
2323
24- static mut TEST_PORT : AtomicU16 = AtomicU16 :: new ( 6479 ) ;
24+ static TEST_PORT : AtomicU16 = AtomicU16 :: new ( 6479 ) ;
2525
2626impl TestConnection {
2727 fn new ( module_name : & str ) -> Self {
28- unsafe {
29- let port = TEST_PORT . fetch_add ( 1 , std:: sync:: atomic:: Ordering :: SeqCst ) ;
28+ let port = TEST_PORT . fetch_add ( 1 , std:: sync:: atomic:: Ordering :: SeqCst ) ;
3029
31- Self {
32- _guards : start_redis ( module_name, port) . expect ( "Redis instance started." ) ,
33- connection : get_redis_connection ( port) . expect ( "Established connection to server." ) ,
34- }
30+ Self {
31+ _guards : start_redis ( module_name, port) . expect ( "Redis instance started." ) ,
32+ connection : get_redis_connection ( port) . expect ( "Established connection to server." ) ,
3533 }
3634 }
3735}
You can’t perform that action at this time.
0 commit comments