Closed FlorianChevassu closed 9 years ago
Hi @FlorianChevassu! Thank you for the kind words.
What version of Rubberduck are you using? Per #289, this issue was resolved in version 1.21. Also, which Host Application are you using (Word, Excel, etc.). Unit testing is not yet supported in all of the Office Applications.
cc: @retailcoder
I too have this problem with the Test Explorer not opening, I just couldn't work out what the cause was until I saw this. Reading that the issue may be caused by protected modules, and realising that I had the Solver Add-In activated (with its associated protected project listed in the Project Explorer), I unloaded the Solver Add-In and now the Test Explorer opens for me.
I am running Excel 2010 (x86) on Windows 7 (x64) with build 1.21.5553.34023 of Rubberduck.
I don't think this is an actual parser issue and is not a duplicate of the other issues I mentioned. I suspect there is a similar snippet as this somewhere that isn't catching the exception. (Or possibly even a different exception being thrown here.)
public void SynchronizeEngineWithIDE()
{
try
{
_testEngine.AllTests = this.VBE.VBProjects
.Cast<VBProject>()
.SelectMany(project => project.TestMethods())
.ToDictionary(test => test, test => _testEngine.AllTests.ContainsKey(test) ? _testEngine.AllTests[test] : null);
}
catch (ArgumentException)
{
System.Windows.Forms.MessageBox.Show(
"Two or more projects containing test methods have the same name and identically named tests. Please rename one to continue.",
"Warning", System.Windows.Forms.MessageBoxButtons.OK,
System.Windows.Forms.MessageBoxIcon.Exclamation);
}
}
Going around the parser speeds things up, but it means going around the "protected project" fix.
Hi @ckuhn203 !
I'm running Rubberduck 1.21 on Excel 2010 32bits on win7 64bits, same as @rossorp !
Thanks all. We're mid stream on a few things right now, but we think we can hotfix this relatively soon. Keep an eye on this issue for updates.
This search represents potential issues to be fixed.
I expect to create and test the 32bit installer this evening.
HotFix is here: https://github.com/retailcoder/Rubberduck/releases/tag/v1.22
Just installed the hotfix (x86 versions) and tested it and I am no longer having any issues with the Test Explorer and protected modules. Thanks for the rapid fix!
Same as @rossorp ! Works great for me !
Thanks !
@rossorp @FlorianChevassu thanks for the bug report! Keep 'em coming. I hope you enjoy the add-in as much as I do.
Hello !
First, let me say that I am impressed by the work you're doing ! I do not particularly like coding in VBA, but I think your addin will help me a lot !
I am testing your addin to see if I can use it in my everyday work. We use some proprietary addins which VBA project is protected by a password. When these addins are loaded, the Rubberduck addin does not work anymore. In particular the UnitTests part. I think you try to parse the protected modules, which throws a COM exception that is not handled.
If you have any question, or cannot reproduce the bug, let me know !
Keep up the good work !
Florian