开发者

Silverlight 4 Unit Testing

I've installed Silve开发者_如何学Gorlight 4 Toolkit April 2010 and have VS 2010 RTM but Silverlight 4 Unit Test Project template is not installed.

Is it by default for this release? If so, how can I use SL4 unit testing?

Thanks.


Solution: The Silverlight 4 Toolkit installer placed the item templates and project templates for the SilverLight Unit Test in c:/program files/microsoft visual studio 10.0/common7/ide, regardless of your actual VS2010 install root.

The upshot is that if your VS2010 installation did not use the default c:/program files/microsoft visual studio 10.0/..., the project and item templates would be in the wrong place after the SL4 install.

The fix would be :

1) Copy the corresponding .zip files 
   from c:\program files\...\common7\ide\... 
   to ?your installpath?\common7\ide\...

   Silverlight Unit Test Framework has templates for CSharp and VisualBasic.

   For example :
   common7\ide\itemtemplates\CSharp\silverlight\1033\Silverlight Unit Test Class.zip
   common7\ide\projecttemplates\CSharp\silverlight\1033\Silverlight Unit Test Project.zip

2) Use the VS command prompt to install the templates with the command :
   devenv /installvstemplates

Now, when you open a New Project in VS2010, you should see the "Silverlight Unit Test application" in the ?Lang?/Silverlight tab of the "Installed Templates" section.

Hope this helps,


Have you also installed the Silverlight 4 Tools? This is not included in the VS 2010 RTM.

My install order:-

  • VS 2010
  • Silverlight Tools 4
  • Silverlight 4 Toolkit April 2010 (http://silverlight.codeplex.com/releases)

In templates I see a "Silverlight Unit Test Application"

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜