File tree Expand file tree Collapse file tree 3 files changed +15
-8
lines changed
Tests/CodexReleaseTests/MarketTests Expand file tree Collapse file tree 3 files changed +15
-8
lines changed Original file line number Diff line number Diff line change @@ -32,14 +32,17 @@ public override string ToString()
32
32
return EthAddress . ToString ( ) ;
33
33
}
34
34
35
- public static bool operator == ( EthAccount a , EthAccount b )
35
+ public static bool operator == ( EthAccount ? a , EthAccount ? b )
36
36
{
37
+ if ( ReferenceEquals ( a , b ) ) return true ;
38
+ if ( ReferenceEquals ( a , null ) ) return false ;
39
+ if ( ReferenceEquals ( b , null ) ) return false ;
37
40
return a . PrivateKey == b . PrivateKey ;
38
41
}
39
42
40
- public static bool operator != ( EthAccount a , EthAccount b )
43
+ public static bool operator != ( EthAccount ? a , EthAccount ? b )
41
44
{
42
- return a . PrivateKey != b . PrivateKey ;
45
+ return ! ( a == b ) ;
43
46
}
44
47
}
45
48
}
Original file line number Diff line number Diff line change @@ -35,14 +35,17 @@ public override string ToString()
35
35
return Address ;
36
36
}
37
37
38
- public static bool operator == ( EthAddress a , EthAddress b )
38
+ public static bool operator == ( EthAddress ? a , EthAddress ? b )
39
39
{
40
+ if ( ReferenceEquals ( a , b ) ) return true ;
41
+ if ( ReferenceEquals ( a , null ) ) return false ;
42
+ if ( ReferenceEquals ( b , null ) ) return false ;
40
43
return a . Address == b . Address ;
41
44
}
42
45
43
- public static bool operator != ( EthAddress a , EthAddress b )
46
+ public static bool operator != ( EthAddress ? a , EthAddress ? b )
44
47
{
45
- return a . Address != b . Address ;
48
+ return ! ( a == b ) ;
46
49
}
47
50
}
48
51
}
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ public RepairTest()
31
31
protected override int NumberOfHosts => 5 ;
32
32
protected override int NumberOfClients => 1 ;
33
33
protected override ByteSize HostAvailabilitySize => SlotSize . Multiply ( 1.1 ) ; // Each host can hold 1 slot.
34
- protected override TimeSpan HostAvailabilityMaxDuration => GetPeriodDuration ( ) * 100 ;
34
+ protected override TimeSpan HostAvailabilityMaxDuration => TimeSpan . FromDays ( 5.0 ) ;
35
35
36
36
private static bool IsPowerOfTwo ( ByteSize size )
37
37
{
@@ -41,6 +41,7 @@ private static bool IsPowerOfTwo(ByteSize size)
41
41
42
42
#endregion
43
43
44
+ [ Ignore ( "Test is ready. Waiting for repair implementation." ) ]
44
45
[ Test ]
45
46
[ Combinatorial ]
46
47
public void RollingRepairSingleFailure (
@@ -172,7 +173,7 @@ private IStoragePurchaseContract CreateStorageRequest(ICodexNode client)
172
173
var config = GetContracts ( ) . Deployment . Config ;
173
174
return client . Marketplace . RequestStorage ( new StoragePurchaseRequest ( cid )
174
175
{
175
- Duration = TimeSpan . FromDays ( 2.0 ) ,
176
+ Duration = HostAvailabilityMaxDuration / 2 ,
176
177
Expiry = TimeSpan . FromMinutes ( 10.0 ) ,
177
178
MinRequiredNumberOfNodes = Slots ,
178
179
NodeFailureTolerance = Tolerance ,
You can’t perform that action at this time.
0 commit comments