简体   繁体   English

Xamarin.UITest,系统图形参考错误

[英]Xamarin.UITest, System Drawing Reference Error

I came into this when I tried to install Xamarin.UITest as NuGet package in an Android project. 当我尝试在Android项目中将Xamarin.UITest作为NuGet软件包安装时,我遇到了这个问题。 When I try to compile the project I have that error: 当我尝试编译项目时,出现该错误:

Can not resolve reference: System.Drawing, referenced by Xamarin.UITest. 无法解析引用:Xamarin.UITest引用的System.Drawing。 Please add a NuGet package or assembly reference for System.Drawing, or remove the reference to Xamarin.UITest. 请为System.Drawing添加NuGet程序包或程序集引用,或删除对Xamarin.UITest的引用。 MyApp.Android MyApp.Android

The Xamarin.UITest NuGet package does not belong in the Android project. Xamarin.UITest NuGet包不属于Android项目。

It must be in its own project which is typically a .NET Framework project. 它必须在自己的项目中,该项目通常是.NET Framework项目。

Here's a sample Xamarin.Forms app that includes a UITest project that you can use for reference: https://github.com/brminnick/UITestSampleApp 这是一个示例Xamarin.Forms应用程序,其中包括一个UITest项目,您可以将其用作参考: https : //github.com/brminnick/UITestSampleApp

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM