New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Exception handling for unit tests and more #2858
Conversation
…setup if there is something to load.
|
||
var referenceLoadingTaskScheduler = ThrottelingTaskScheduler(_maxReferenceLoadingConcurrency); | ||
State.OnStatusMessageUpdate(ParserState.LoadingReference.ToString()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this get the localized resource for the ParserState.LoadingReference
state? The InspectionUI
resources will be moving to the Rubberduck.Parsing
assembly; perhaps the ParserState
enum resources should be moved to ParsingText.resx
?
@@ -839,22 +839,12 @@ private void SyncComReferences(IReadOnlyList<IVBProject> projects, CancellationT | |||
var unmapped = new ConcurrentBag<IReference>(); | |||
|
|||
var referencesToLoad = GetReferencesToLoadAndSaveReferencePriority(projects); | |||
|
|||
State.OnStatusMessageUpdate(ParserState.LoadingReference.ToString()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And I just realized why that "Loading references" caption didn't follow the localization settings...
@@ -6,6 +6,8 @@ namespace Rubberduck.VBEditor.Application | |||
{ | |||
public class ExcelApp : HostApplicationBase<Microsoft.Office.Interop.Excel.Application> | |||
{ | |||
public const int MaxPossibleLengthOfProcedureName = 255; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We might want to have that one in HostApplicationBase
, no?
This and that:
Slightly more safety for long procedure names in Excel. (If > 255 chars, drop the filename.)
Catching and logging of COMExceptions thrown during running the unit tests. (
Application.Run
might not like what we are feeding it.) Exception gets logged and test gets set toInconclusive - Unexpected COM error
.Small refactoring of
SyncCOMReferences
in theParseCoordinator
. Now, the setup for parallelism gets only performed if there is actually soemthing to load.