File tree 1 file changed +5
-2
lines changed
src/Meadow.UnitTestTemplate
1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ namespace Meadow.UnitTestTemplate
21
21
public abstract class ContractTest
22
22
{
23
23
#region Fields
24
- private ulong _baseSnapshotID ;
24
+ private ulong ? _baseSnapshotID ;
25
25
private static Semaphore _sequentialExecutionSemaphore = new Semaphore ( 1 , 1 ) ;
26
26
#endregion
27
27
@@ -98,7 +98,10 @@ public async Task OnTestInitialize()
98
98
InternalTestState . StartTime = DateTimeOffset . UtcNow ;
99
99
100
100
// Create a snapshot to revert to when test is completed.
101
- _baseSnapshotID = await TestServices . TestNodeClient . Snapshot ( ) ;
101
+ if ( ! _baseSnapshotID . HasValue )
102
+ {
103
+ _baseSnapshotID = await TestServices . TestNodeClient . Snapshot ( ) ;
104
+ }
102
105
103
106
// Determine what message to log
104
107
if ( InternalTestState . InExternalNodeContext )
You can’t perform that action at this time.
0 commit comments