From 635c9ff4e17411f6eec56e4038f5cc714d5fafb4 Mon Sep 17 00:00:00 2001 From: Siegfried Pammer Date: Fri, 5 Jun 2009 16:44:03 +0000 Subject: [PATCH] - added additional logging to Unit Test profiling - fixed bug in Extract Method git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/branches/3.0@4238 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61 --- src/AddIns/Misc/SharpRefactoring/Src/MethodExtractorBase.cs | 2 +- src/AddIns/Misc/UnitTesting/Src/RunTestCommands.cs | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/AddIns/Misc/SharpRefactoring/Src/MethodExtractorBase.cs b/src/AddIns/Misc/SharpRefactoring/Src/MethodExtractorBase.cs index b5492b3af2..6a1f117683 100644 --- a/src/AddIns/Misc/SharpRefactoring/Src/MethodExtractorBase.cs +++ b/src/AddIns/Misc/SharpRefactoring/Src/MethodExtractorBase.cs @@ -128,7 +128,7 @@ namespace SharpRefactoring code = code.TrimEnd('\r', '\n', ' ', '\t'); - Dom.IMember p = GetParentMember(this.textEditor, this.currentSelection.StartPosition.Line, this.currentSelection.StartPosition.Column); + Dom.IMember p = GetParentMember(this.textEditor, this.currentSelection.StartPosition.Line + 1, this.currentSelection.StartPosition.Column + 1); TextLocation loc = new ICSharpCode.TextEditor.TextLocation( p.BodyRegion.EndColumn - 1, p.BodyRegion.EndLine - 1); diff --git a/src/AddIns/Misc/UnitTesting/Src/RunTestCommands.cs b/src/AddIns/Misc/UnitTesting/Src/RunTestCommands.cs index f6f9bd64f0..0e4f8c4222 100644 --- a/src/AddIns/Misc/UnitTesting/Src/RunTestCommands.cs +++ b/src/AddIns/Misc/UnitTesting/Src/RunTestCommands.cs @@ -532,6 +532,7 @@ namespace ICSharpCode.UnitTesting startInfo.Arguments = helper.GetArguments(); startInfo.WorkingDirectory = UnitTestApplicationStartHelper.UnitTestApplicationDirectory; + LoggingService.Info("starting profiler..."); ProfilerService.CurrentProfiler.Start(startInfo, path, delegate { AfterFinish(helper, path); }); } @@ -539,6 +540,7 @@ namespace ICSharpCode.UnitTesting { ProfilerService.AddSessionToProject(helper.Project, path); WorkbenchSingleton.SafeThreadAsyncCall(TestsFinished); + LoggingService.Info("shutting profiler down..."); } public override void Run() @@ -554,6 +556,7 @@ namespace ICSharpCode.UnitTesting protected override void OnStop() { if (ProfilerService.CurrentProfiler.IsRunning) { + LoggingService.Info("stopping profiler..."); ProfilerService.CurrentProfiler.Stop(); } }