在哪里可以找到" Microsoft.VisualStudio.TestTools.UnitTesting"缺少DLL? [英] Where to find "Microsoft.VisualStudio.TestTools.UnitTesting" missing dll?

查看:2604
本文介绍了在哪里可以找到" Microsoft.VisualStudio.TestTools.UnitTesting"缺少DLL?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我收到以下错误在我的 C#Visual Studio项目

I am getting following error in my C# visual studio project:

The type or namespace name 'VisualStudio' does 
not exist in the namespace 'Microsoft' (are you missing an assembly reference?)

不存在

我也试图找到 microsoft.dll 的文件,但不能得到任何引用。 ?
我是寻找错误的 DLL

I also tried to find the microsoft.dll file but couldn't get any reference. Am i searching the wrongdll?

using Microsoft.VisualStudio.TestTools.UnitTesting;  
using Kya.MsFx.Services.Swiper;

namespace Kya.MsFx.Devices.Swiper.Test
{
[TestClass]
public class SwiperWindowTest
{

    private SwiperWebServiceHost m_SwiperWS = null;
    /// <summary>
    ///     start web service on a separate thread, so tests 
    ///     can be executed withut blocking the application thread
    /// </summary>
    [ClassInitialize]
    public void SetupSwiperTests() {

        m_SwiperWS = SwiperWebServiceHost.StartService();

    }

    /// <summary>
    /// Stop service started during class initialize and kill the thread
    /// </summary>
    [ClassCleanup]
    public void CleanupSwiperTests() {
        m_SwiperWS.Stop();
    }


    /// <summary>
    ///   simulate init, swipe, clear operations
    /// </summary>
    [TestMethod]
    public void TestSwiperService()
    {
        MessageBox.Show("test");
    }
}
}



版权kaarya 2010-2012

copyright kaarya 2010-2012

推荐答案

您必须添加引用

Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll 

它可以在C发现: \Program Files\Microsoft的Visual Studio 10.0\Common7\IDE\PublicAssemblies\目录(VS2010专业及以上学历; .NET框架4.0)。

It can be found at "C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\PublicAssemblies\" directory (for VS2010 professional or above; .NET Framework 4.0).

你的项目或右键单击并选择:添加引用...> .NET:

or right click on your project and select: Add Reference... > .NET:

这篇关于在哪里可以找到&QUOT; Microsoft.VisualStudio.TestTools.UnitTesting&QUOT;缺少DLL?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆