为什么 Gallio 似乎需要在名为 GallioBundle-3.1.397.0/bin 的文件夹中才能运行

发布于 2024-09-06 22:06:25 字数 1852 浏览 4 评论 0原文

我想使用 Icarus 和/或 Echo 运行 MbUnit 测试,而无需安装 Gallio。我已将 GallioBundle/bin 中的所有文件复制到项目文件夹中名为 Third Party/MbUnit 的文件夹中。

当我双击 Gallio.Icarus.exe 时,它不会加载或执行任何操作。

当我从命令行运行 gallio.echo.exe 时,出现以下错误:

开始时间:下午 1:07 初始化运行时并加载插件。 停止时间:下午 1:07(总执行时间:0.313 秒) 错误:发生致命异常。 Gallio.Runtime.RuntimeException:无法解析服务类型“Gallio.Runner.Projects.ITestProjectManager”的组件,因为似乎没有为该服务类型注册和启用任何组件。 在 c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runtime\Extensibility\RegistryServiceLocator.cs 中的 Gallio.Runtime.Extensibility.RegistryServiceLocator.ResolveNonDisabledDescriptor(Type serviceType):第 202 行 在 c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runtime\Extensibility\RegistryServiceLocator.cs 中的 Gallio.Runtime.Extensibility.RegistryServiceLocator.ResolveImpl(Type serviceType):第 161 行 在 c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runtime\Extensibility\RegistryServiceLocator.cs 中的 Gallio.Runtime.Extensibility.RegistryServiceLocator.ResolveTService:第 52 行 在 c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runner\TestLauncher.cs 中的 Gallio.Runner.TestLauncher.RunWithRuntime() 处:第 511 行 在 c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runner\TestLauncher.cs 中的 Gallio.Runner.TestLauncher.Run():第 474 行 在 Gallio.Echo.EchoProgram.RunTests(ILogger 记录器) 在 Gallio.Echo.EchoProgram.RunImpl(String[] args) 在 c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runtime\ConsoleSupport\ConsoleProgram.cs 中的 Gallio.Runtime.ConsoleSupport.ConsoleProgram`1.Run(IRichConsole console, String[] args) 处:第198行

但是,如果我从 d/l 文件夹中解压的位置运行它:

GallioBundle-3.1.397.0/bin Icarus UI 出现。另外...当我在命令行运行 gallio.echo 时,它没有给出任何错误。这对我来说毫无意义,但确实如此。

为什么 Gallio 不能从我的项目文件夹运行?

I want to run MbUnit tests with Icarus and/or Echo without having to install Gallio. I have copied all of the files in the GallioBundle/bin into a folder named Third Party/MbUnit in our project folder.

When I double click on Gallio.Icarus.exe it doesn't load or do anything.

When I run gallio.echo.exe from the command line I get the following error:

Start time: 1:07 PM
Initializing the runtime and loading plugins.
Stop time: 1:07 PM (Total execution time: 0.313 seconds)
Error: A fatal exception occurred.
Gallio.Runtime.RuntimeException: Could not resolve component for service type 'Gallio.Runner.Projects.ITestProjectManager' because there do not appear to be any components registered and enabled for that service type.
at Gallio.Runtime.Extensibility.RegistryServiceLocator.ResolveNonDisabledDescriptor(Type serviceType) in c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runtime\Extensibility\RegistryServiceLocator.cs:line 202
at Gallio.Runtime.Extensibility.RegistryServiceLocator.ResolveImpl(Type serviceType) in c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runtime\Extensibility\RegistryServiceLocator.cs:line 161
at Gallio.Runtime.Extensibility.RegistryServiceLocator.ResolveTService in c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runtime\Extensibility\RegistryServiceLocator.cs:line 52
at Gallio.Runner.TestLauncher.RunWithRuntime() in c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runner\TestLauncher.cs:line 511
at Gallio.Runner.TestLauncher.Run() in c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runner\TestLauncher.cs:line 474
at Gallio.Echo.EchoProgram.RunTests(ILogger logger)
at Gallio.Echo.EchoProgram.RunImpl(String[] args)
at Gallio.Runtime.ConsoleSupport.ConsoleProgram`1.Run(IRichConsole console, String[] args) in c:\RelEng\Projects\MbUnit v3.1\Work\src\Gallio\Gallio\Runtime\ConsoleSupport\ConsoleProgram.cs:line 198

However, if I run it from where I have unzipped in my d/l folder to:

GallioBundle-3.1.397.0/bin Icarus UI comes up. Also... gallio.echo gives no errors when I run it at the command line. This makes no sense to me but there it is.

Why won't Gallio run from my project's folder?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

梦魇绽荼蘼 2024-09-13 22:06:25

它应该工作正常。 Gallio 实际上并不关心文件夹叫什么。
当某些文件丢失时,通常会出现上述错误。

另一件可以尝试的事情可能是运行“Gallio.Utility.exe ResetInstallationId”

It should work fine. Gallio really doesn't care about what the folder is called.
The error above usually appears when some files are missing.

Another thing to try may be to run "Gallio.Utility.exe ResetInstallationId"

ι不睡觉的鱼゛ 2024-09-13 22:06:25

文件夹的名称并不重要。

首次运行时,Gallio 会扫描该文件夹中的插件,并将它们写入 %LocalAppData%\Gallio\Plugin Metadata Cache 中的 XML 文件。如果您在损坏的 Gallio 安装中运行可执行文件(例如,某些文件可能丢失),Gallio 会缓存此文件,即使您稍后修复这些文件,它仍然认为安装已损坏,因为它会看到其元数据的缓存视图。当您将 Gallio 移动到另一个文件夹时,它会重新创建该文件夹的缓存,并且一切都会再次开始工作(前提是文件实际上都在那里)。

解决方法是简单地擦除 Plugin Metadata Cache 文件夹。

The name of the folder doesn't matter.

On first run Gallio scans for plugins in the folder and writes them to an XML file in %LocalAppData%\Gallio\Plugin Metadata Cache. If you run an executable in a broken installation of Gallio (e.g. some files may be missing) Gallio caches this, and even if you later fix the files, it still believes that the installation is broken, because it sees the cached view of its metadata. When you move Gallio into a different folder it recreates the cache for that folder and things start to work again (provided the files are actually all there).

The fix then is to simply wipe the Plugin Metadata Cache folder.

触ぅ动初心 2024-09-13 22:06:25

看来,将二进制文件放在名为 MbUnit 的文件夹中是导致问题的原因。当我将文件夹重命名为 Gallio 时,一切都开始正常工作。

Gallio 开发人员告诉我他们不能复制这个...但它是一致的,我什至将文件夹重命名回来,错误又出现了。

It seems that having the binary files in a folder named MbUnit was causing the problem. When I renamed the folder to Gallio everything started working correctly.

The Gallio devs have told me they can't duplicate this... but it was consistent and I even renamed the folder back and the error recurred.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文