public override void Dispose() { // Do this first, because the next step will // make the downstream runner inaccessible. base.Dispose(); if (this.agent != null) { log.Info("Stopping remote agent"); agent.Stop(); this.agent = null; } }
public override void Unload() { if (Test != null) { log.Info("Unloading " + Path.GetFileName(Test.TestName.Name)); this.TestRunner.Unload(); this.TestRunner = null; } if (this.agent != null) { log.Info("Stopping remote agent"); agent.Stop(); this.agent = null; } }
public override void Dispose() { // Do this first, because the next step will // make the downstream runner inaccessible. base.Dispose(); if (this.agent != null) { log.Info("Stopping remote agent"); try { agent.Stop(); } catch { // Ignore any exception } finally { this.agent = null; } } }