File tree 2 files changed +7
-8
lines changed
2 files changed +7
-8
lines changed Original file line number Diff line number Diff line change @@ -205,7 +205,6 @@ impl InspectorStackBuilder {
205
205
stack. collect_logs ( logs. unwrap_or ( true ) ) ;
206
206
stack. print ( print. unwrap_or ( false ) ) ;
207
207
stack. tracing ( trace_mode) ;
208
- stack. revert_diagnostic ( !trace_mode. is_none ( ) ) ;
209
208
210
209
stack. enable_isolation ( enable_isolation) ;
211
210
stack. odyssey ( odyssey) ;
@@ -436,8 +435,15 @@ impl InspectorStack {
436
435
}
437
436
438
437
/// Set whether to enable the tracer.
438
+ /// Revert diagnostic inspector is activated when `mode != TraceMode::None`
439
439
#[ inline]
440
440
pub fn tracing ( & mut self , mode : TraceMode ) {
441
+ if mode. is_none ( ) {
442
+ self . revert_diag = None ;
443
+ } else {
444
+ self . revert_diag = Some ( RevertDiagnostic :: default ( ) ) ;
445
+ }
446
+
441
447
if let Some ( config) = mode. into_config ( ) {
442
448
* self . tracer . get_or_insert_with ( Default :: default) . config_mut ( ) = config;
443
449
} else {
@@ -452,12 +458,6 @@ impl InspectorStack {
452
458
script_address;
453
459
}
454
460
455
- /// Set the revert diagnostic inspector.
456
- #[ inline]
457
- pub fn revert_diagnostic ( & mut self , yes : bool ) {
458
- self . revert_diag = yes. then ( RevertDiagnostic :: default)
459
- }
460
-
461
461
/// Collects all the data gathered during inspection into a single struct.
462
462
#[ inline]
463
463
pub fn collect ( self ) -> InspectorData {
Original file line number Diff line number Diff line change @@ -332,7 +332,6 @@ impl TestRunnerConfig {
332
332
inspector. collect_coverage ( self . coverage ) ;
333
333
inspector. enable_isolation ( self . isolation ) ;
334
334
inspector. odyssey ( self . odyssey ) ;
335
- inspector. revert_diagnostic ( true ) ;
336
335
// inspector.set_create2_deployer(self.evm_opts.create2_deployer);
337
336
338
337
// executor.env_mut().clone_from(&self.env);
You can’t perform that action at this time.
0 commit comments