Quantcast
Channel: Category Name
Viewing all 10804 articles
Browse latest View live

Git repo tokens for the security service

$
0
0

The VSTS platform offers a security REST endpoint which allows you to add and remove permissions on resources. (To understand the rest of this blog post, you’re going to want to skim those docs first.) Several of the security APIs, as well as TFSSecurity.exe, expect a token identifying the resource to operate on. The token format varies across resources. A Git repository’s token is different from a work item’s token since they have distinct needs. How do you determine the token for a resource you want to secure?

You can often use the VSTS web UI coupled with Fiddler to learn the token for a particular resource. But maybe the thing you want to protect doesn’t exist yet – for example, if you want to put permissions on a Git branch that doesn’t currently exist. It would be nice to be able to generate a token without snooping on the web.

For a historical reason we’ll discuss below, Git tokens are, shall we say, a bit inscrutable. Here’s an actual example from our main development repo (I’ve obfuscated the GUIDs):

repoV2/212d1460-2143-4296-9771-c54336dbf3d3/393d8e86-ed2b-473f-8480-0cf728c1f866/refs/heads/6d0061007300740065007200/

The token is part of a hierarchical security namespace. It’s a sequence of token parts separated by “/”. Breaking down those components:

Token partExplanation
repoV2token root – lets the security service know this is for a Git repo
212d1460-2143-4296-9771-c54336dbf3d3project ID
393d8e86-ed2b-473f-8480-0cf728c1f866repo ID
refs/heads/6d0061007300740065007200branch – this is “master”

Since the namespace is hierarchical, the token could have stopped at any separator. Any ACEs you added would then apply to everything below that point in the hierarchy. In this case, the token goes all the way to the master branch. The project and repo IDs are fairly straightforward – you can get them from several different APIs (repo, project, or both). But how the heck did we get “refs/heads/6d0061007300740065007200” from “master”?!

The historical reason I mentioned above is that security tokens are case-insensitive. But in Git, ref names like branches are case-sensitive, so “master” and “Master” are not the same branch. They should not be affected by the same security token! We needed a way to encode case-sensitive names in a case-insensitive transport. There are many possible ways to do this. We chose one that has a combination of good performance and relatively easy debuggability.

The algorithm looks a little complicated until you realize what’s going on. It’s encoding the hexadecimal value of each character as a string. Also, because we’re in C#, the source string is (and thus characters are) UTF-16 little-endian. For instance, in UTF-16 the character “m” is represented by the bytes 0x6d00. Thus, the first four characters of the encoded string are “6d00”. Only the non-slash characters are encoded this way; a slash in the source remains a slash in the output. So a branch “user/mattc/feature1” becomes “7500730065007200/6d006100740074006300/66006500610074007500720065003100/”. Also, “refs/heads/” is the place where Git stores branch refs. On VSTS that’s always lowercase and from a small range of characters, so we don’t have to encode it. Instead, we use it directly to save a bit of space.

Here are code snippets in two different languages which implement the algorithm. Note that these are like Raymond Chen’s “little programs” – they ignore a lot of error-checking and defensive coding practices in the name of being easier to understand.

C#:

Python:

Many thanks to Congyi Wu,Philip Kelley, and Kevin David for their help preparing this blog post and sample code.


The week in .NET – On .NET with Scott Hunter, On .NET with Matt Watson, MessagePack

$
0
0

Previous posts:

On .NET

We recorded two videos last week. In the first one, Scott Hunter showed Visual Studio 2017 and .NET Core SDK 1.0:

In the second video, Matt Watson from Stackify showed us Prefix, a free lightweight dev tool that shows you real-time logs, errors, queries, and more, and Retrace, a powerful commercial solution for gathering and analysis of performance data.

We have no show this week due to a last minute cancellation.

Happy Birthday .NET!

Last month we got together with the Microsoft Alumni Network and threw a big .NET 15th birthday bash with former .NET team members & rock stars. We caught up with Dee Dee Walsh, who was one of the original Developer Relations and Community person starting before Visual Studio! Dee Dee was most famously known for her Geekfest parties and helped foster the Microsoft developer community and MVP program. Happy Birthday .NET!

Package of the week: MessagePack for C#

I’ve featured quite a few serialization libraries in the past. I have another one for you this week. MessagePack is an efficient binary serialization format that is supported on more than 50 development platforms. It’s also used by Redis. There are at least five different implementations of MessagePack for .NET, but the one I want to showcase today is MessagePack for C# by Yoshifumi Kawai, also known as neuecc, who also built ZeroFormatter. His library supports LZ4 compression, and achieves extremely fast speeds on both serialization and deserialization, with a very compact serialized size.

First, you can define a serializable data object.

And then you can serialize and deserialize it.

User group meeting of the week: the state of .NET in Sydney

On Wednesday, March 15, at 6:30PM in Sydney, Australia, the Sydney .NET User Group holds a meeting on the state of .NET, presented by Markus Egger.

.NET

ASP.NET

C#

F#

F# eXchange 2017 is in London, April 6-7. Speakers include Don Syme, Phillip Carter, Scott Wlaschin, and many others.

New F# Language Suggestions:

Check out F# Weekly for more great content from the F# community.

Xamarin

UWP

Data

Games

And this is it for this week!

Contribute to the week in .NET

As always, this weekly post couldn’t exist without community contributions, and I’d like to thank all those who sent links and tips. The F# section is provided by Phillip Carter, the gaming section by Stacey Haffner, and the Xamarin section by Dan Rigby, and the UWP section by Michael Crump.

You can participate too. Did you write a great blog post, or just read one? Do you want everyone to know about an amazing new contribution or a useful library? Did you make or play a great game built on .NET?
We’d love to hear from you, and feature your contributions on future posts:

This week’s post (and future posts) also contains news I first read on The ASP.NET Community Standup, on Weekly Xamarin, on F# weekly, and on Chris Alcock’s The Morning Brew.

Announcing Nightly Releases for the Visual F# Tools

$
0
0

Announcing Nightly Releases for the Visual F# Tools

In our previous blog post announcing F# 4.1 and a release of the Visual F# Tools, we mentioned that a new release model for the Visual F# tools would be coming soon.

That time is now.

To recap, nightly builds of the tools are successful builds of the latest master branch of the tools, after having been run through our Continuous Integration system successfully. These will include new features, bug fixes, and improvements to existing features that will eventually make their way into a forthcoming Visual Studio update or release.

For VS 2017 RTW, it is highly recommended that you install the latest nightly. There have been a number of bug fixes, performance improvements, and new features that make the overall experience better than what was made available at the VS 2017 release.

Installing Nightly Builds of the Visual F# Tools

There are a few ways you can get nightly builds.

Configuring Extensions and Updates within Visual Studio (Recommended)

This is the recommended approach. The following steps will allow you to configure Extensions and Updates to point to the Visual F# Tools nightly feed. When a new nightly VSIX is published, you will get a notification in Visual Studio.

  1. Open Tools -> Extensions and Updates.
  2. Click "Change your Extensions and Updates settings" on the bottom-left corner.

Change your Extensions and Updates settings

  1. Click "Add" under "Additional Extension Galleries".

Additional Extension Galleries

  1. Under "Name", enter anything you like. Under "URL", enter https://dotnet.myget.org/F/fsharp/vsix.

Configure the Name and URL

  1. Click "Apply".
  2. Click "OK".

It may take a few minutes for VS to refresh the feed, depending on your machine. Once that has happened, you can open Tools -> Extensions and Updates and notice that there is an update to the Visual F# tools!

Installing a Nightly VSIX Manually

If you don’t wish to configure Visual Studio to check for updates to the nightly builds, you can always install a given nightly VSIX manually. You can also use this method to access a particular nightly VSIX.

  1. Visit [URL HERE]
  2. Download the latest VSIX (or any you wish, really)
  3. Once it has downloaded, install it by double-clicking. You’ll have to close Visual Studio to install it.

This may be helpful if your code worked fine with a previous nightly build, but was broken in the latest one.

Uninstalling Nightly Builds to Revert to a Release Build

If you wish to revert your installation of a nightly build, the easiest way is with the Visual Studio Developer Command Prompt. You can open it by searching for "Visual Studio Developer Command Prompt" through the Windows Start Menu. Then, run the following command:

VSIXInstaller.exe /u:VisualFSharp

This will uninstall your nightly build. This will automatically bring you back to the latest release build of the Visual F# Tools that you have installed.

We’re really excited to have nightly builds for the Visual F# Tools. We encourage you to try them out and provide feedback, especially on new features. You can track any progress for a given feature, bug, or improvement on the Visual F# Github repository.

Thanks!
– The Visual F# Team

Over 300,000 Square Kilometers of Imagery Released in Italy and Switzerland

$
0
0

We are excited to announce the release of new imagery in Italy and Switzerland. This latest imagery release includes 297,000 square kilometers in Italy and 38,000 square kilometers in Switzerland.

Below are examples of the beautiful imagery of Italy and Switzerland now available:

Italy

Palmanova, located in northeastern Italy, is a concentric city in the shape of a star. It is an example of the star fort from the renaissance period, and was built with military and societal considerations incorporated into its plans.

Palmanova, Italy

Switzerland

The city of Bern, referred to as the federal city, is the fourth most populous city in Switzerland. Also, the historic Old Town was designated as a UNESCO World Heritage Site in 1983.

Bern, Switzerland

Explore even more points of interest in Italy and Switzerland on Bing Maps.

To learn more about how you can incorporate maps in your apps, visit www.microsoft.com/maps.  

- Bing Maps Team

ZEIT now deployments of open source ASP.NET Core web apps with Docker

$
0
0

ZEIT is a new cloud service and "now" is the name of their deployment tool. ZEIT World is their DNS service. If you head over to https://zeit.co/ you'll see a somewhat cryptic animated gif that shows how almost impossibly simple it is to deploy a web app with ZEIT now.

ZEIT works with .NET Core and ASP.NET

You can make a folder, put an index.html (for example) in it and just run "now." You'll automatically get a website with an autogenerated name and it'll be live. It's probably the fastest and easiest deploy I've ever seen. Remember when Heroku (then Azure, then literally everyone) started using git for deployment? Clearly being able to type "now" and just get a web site on the public internet was the next step. (Next someone will make "up" which will then get replaced with just pressing ENTER on an empty line! ;) )

Jokes aside, now is clean and easy. I appreciate their organizational willpower to make an elegant and simple command line tool. I suspect it's harder than it looks to keep things simple.

All of their examples use JavaScript and node.js, but they also support Docker, which means they support open source ASP.NET Core on .NET Core! But do they know they do? ;) Let's find out.

And more importantly, how easy is it? Can I take a site from concept to production in minutes? Darn tootin' I can.

First, make a quick ASP.NET Core app. I'll use the MVC template with Bootstrap.

C:\Users\scott\zeitdotnet>dotnet new mvc
Content generation time: 419.5337 ms
The template "ASP.NET Core Web App" created successfully.

I'll do a quick dotnet restore to get the packages for my project.

C:\Users\scott\zeitdotnet>dotnet restore
Restoring packages for C:\Users\scott\zeitdotnet\zeitdotnet.csproj...
Generating MSBuild file C:\Users\scott\zeitdotnet\obj\zeitdotnet.csproj.nuget.g.props.
Generating MSBuild file C:\Users\scott\zeitdotnet\obj\zeitdotnet.csproj.nuget.g.targets.
Writing lock file to disk. Path: C:\Users\scott\zeitdotnet\obj\project.assets.json
Restore completed in 2.93 sec for C:\Users\scott\zeitdotnet\zeitdotnet.csproj.

NuGet Config files used:
C:\Users\scott\AppData\Roaming\NuGet\NuGet.Config
C:\Program Files (x86)\NuGet\Config\Microsoft.VisualStudio.Offline.config

Feeds used:
https://api.nuget.org/v3/index.json
C:\LocalNuGet
C:\Program Files (x86)\Microsoft SDKs\NuGetPackages\

Now I need to add a Dockerfile. I'll make one in the root that looks like this:

FROM microsoft/aspnetcore
LABEL name="zeitdotnet"
ENTRYPOINT ["dotnet", "zeitdotnet.dll"]
ARG source=.
WORKDIR /app
EXPOSE 80
COPY $source .

Note that I could have ZEIT build my app for me if I used the aspnetcore Dockerfile that includes the .NET Core SDK, but that would not only make my deployment longer, it would also make my docker images a LOT larger. I want to include JUST the .NET Core runtime in my image, so I'll build and publish locally.

ZEIT now is going to need to see my Dockerfile, and since I want my app to include the binaries (I don't want to ship my source in the Docker image up to ZEIT) I need to mark my Dockerfile as "Content" and make sure it's copied to the publish folder when my app is built and published.

Always
I'll add this my project's csproj file. If I was using Visual Studio, this is the same as right clicking on the Properties of the Dockerfile, setting it to Content and then "Always Copy to Output Directory."

Now I'll just build and publish to a folder with one command:

C:\Users\scott\zeitdotnet>dotnet publish
Microsoft (R) Build Engine version 15.1.548.43366
Copyright (C) Microsoft Corporation. All rights reserved.

zeitdotnet -> C:\Users\scott\zeitdotnet\bin\Debug\netcoreapp1.1\zeitdotnet.dll

And finally, from the .\bin\Debug\netcoreapp1.1\ folder I run "now." (Note that I've installed now and signed up for their service, of course.)

C:\Users\scott\zeitdotnet\bin\Debug\netcoreapp1.1\publish>now
> Deploying ~\zeitdotnet\bin\Debug\netcoreapp1.1\publish
> Ready! https://zeitdotnet-gmhcxevqkf.now.sh (copied to clipboard) [3s]
> Upload [====================] 100% 0.0s
> Sync complete (196.18kB) [2s]
> Initializing…
> Building
>▲ docker build
> ---> 035a0a1401c3
> Removing intermediate container 289b9e4ce5d9
> Step 6 : EXPOSE 80
> ---> Running in efb817308333
> ---> fbac2aaa3039
> Removing intermediate container efb817308333
> Step 7 : COPY $source .
> ---> ff009cfc48ea
> Removing intermediate container 8d650c1867cd
> Successfully built ff009cfc48ea
>▲ Storing image
>▲ Deploying image
> Deployment complete!

Now has put the generated URL in my clipboard (during deployment you'll get redirected to a lovely status page) and when it's deployed I can visit my live site. But, that URL is not what I want. I want to use a custom URL.

I can take one of my domains and set it up with ZEIT World's DNS but I like DNSimple (ref).

I can add my domain as an external one after adding a TXT record to my DNS to verify I own it. Then I setup a CNAME to point my subdomain to alias.zeit.co.

C:\Users\scott\Desktop\zeitdotnet>now alias https://zeitdotnet-gmhcxevqkf.now.sh http://zeitdotnet.hanselman.com
> zeitdotnet.hanselman.com is a custom domain.
> Verifying the DNS settings for zeitdotnet.hanselman.com (see https://zeit.world for help)
> Verification OK!
> Provisioning certificate for zeitdotnet.hanselman.com
> Success! Alias created:
https://zeitdotnet.hanselman.com now points to https://zeitdotnet-gmhcxevqkf.now.sh [copied to clipboard]

And that's it. It even has a nice SSL certificate that they applied for me. It doesn't terminate to SSL all the way into the docker container's Kestral web server, but for most things that aren't banking it'll be just fine.

All in all, a lovely experience. Here's my Hello World ASP.NE Core app running in ZEIT and deployed with now  at http://zeitdotnet.hanselman.com (if you are visiting this long after this was published, this sample MAY be gone.)

I am still learning about this (this whole exercise was about 30 total minutes and asking Glenn Condron a docker question) so I'm not clear how this would work in a large multi-container deployment, but as long as your site is immutable (don't write to the container's local disk!) ZEIT says it will scale your single containers. Perhaps docker-compose support is coming?


Sponsor: Did you know VSTS can integrate closely with Octopus Deploy? Join Damian Brady and Brian A. Randell as they show you how to automate deployments from VSTS to Octopus Deploy, and demo the new VSTS Octopus Deploy dashboard widget. Register now!



© 2017 Scott Hanselman. All rights reserved.
     

Never Miss a Score with Bing Sportscaster

$
0
0

Never miss a score with the Bing Sportscaster bot.

To chat with our Sportscaster bot on Facebook Messenger, search ‘Bing Sportscaster’ and start the conversation. To get all the news you want about your favorite teams and players, tell Sportscaster your favorite team’s name and the bot takes it from there.

Bing Sportscaster

Curious about the schedule and who Bing predicts is going to win?

Bing Sportscaster

Too busy for a deep dive, but want to know if your team advanced to the next round? Follow them and the Bing Sportscaster will message you when there is a scoring play or interesting news.

Bing Sportscaster

Let the Bing Sportscaster show you what it can do with college hoops. Tell it who you like, and let the scores and rankings follow you.

In addition to the Bing Sportscaster bot, keep your schedule clear of any conflicts at game time by leveraging Outlook’s Interesting calendars.

Outlook Calendar - Interesting calendar in the ribbon

With a few simple clicks Outlook will add the entire playoff schedule, so you can stay focused on the game.

- The Bing Team

Bing Sportscaster

Visual Studio 2017 Update Preview

$
0
0
Visual Studio 2017 Update Preview

Creators Update SDK support in Visual Studio 2017

$
0
0
Creators Update SDK support in Visual Studio 2017

Options for CSS and JS Bundling and Minification with ASP.NET Core

$
0
0

Maria and I were updating the NerdDinner sample app (not done yet, but soon) and were looking at various ways to do bundling and minification of the JSS and CS. There's runtime bundling on ASP.NET 4.x but in recent years web developers have used tools like Grunt or Gulp to orchestrate a client-side build process to squish their assets. The key is to find a balance that gives you easy access to development versions of JS/CSS assets when at dev time, while making it "zero work" to put minified stuff into production. Additionally, some devs don't need the Grunt/Gulp/npm overhead while others absolutely do. So how do you find balance? Here's how it works.

I'm in Visual Studio 2017 and I go File | New Project | ASP.NET Core Web App. Bundling isn't on by default but the configuration you need IS included by default. It's just minutes to enable and it's quite nice.

In my Solution Explorer is a "bundleconfig.json" like this:

// Configure bundling and minification for the project.
// More info at https://go.microsoft.com/fwlink/?LinkId=808241
[
{
"outputFileName": "wwwroot/css/site.min.css",
// An array of relative input file paths. Globbing patterns supported
"inputFiles": [
"wwwroot/css/site.css"
]
},
{
"outputFileName": "wwwroot/js/site.min.js",
"inputFiles": [
"wwwroot/js/site.js"
],
// Optionally specify minification options
"minify": {
"enabled": true,
"renameLocals": true
},
// Optionally generate .map file
"sourceMap": false
}
]

Pretty simple. Ins and outs. At the top of the VS editor you'll see this yellow prompt. VS knows you're in a bundleconfig.json and in order to use it effectively in VS you grab a small extension. To be clear, it's NOT required. It just makes it easier. The source is at https://github.com/madskristensen/BundlerMinifier. Slip this UI section if you just want Build-time bundling.

BundleConfig.json

If getting a prompt like this bugs you, you can turn all prompting off here:

Tools Options HTML Advanced Identify Helpful Extensions

Look at your Solution Explorer. See under site.css and site.js? There are associated minified versions of those files. They aren't really "under" them. They are next to them on the disk, but this hierarchy is a nice way to see that they are associated, and that one generates the other.

Right click on your project and you'll see this Bundler & Minifier menu:

Bundler and Minifier Menu

You can manually update your Bundles with this item as well as see settings and have bundling show up in the Task Runner Explorer.

Build Time Minification

The VSIX (VS extension) gives you the small menu and some UI hooks, but if you want to have your bundles updated at build time (useful if you don't use VS!) then you'll want to add a NuGet package called BuildBundlerMinifier.

You can add this NuGet package SEVERAL ways. Which is awesome.

  • Add it from the Manage NuGet Packages menu
  • Add it from the command line via "dotnet add package BuildBundlerMinifier"
    • Note that this adds it to your csproj without you having to edit it! It's like "nuget install" but adds references to projects!  The dotnet CLI is lovely.
  • If you have the VSIX installed, just right-click the bundleconfig.json and click "Enable bundle on build..." and you'll get the NuGet package.
    Enable bundle on build

Now bundling will run on build...

c:\WebApplication8\WebApplication8>dotnet build
Microsoft (R) Build Engine version 15
Copyright (C) Microsoft Corporation. All rights reserved.

Bundler: Begin processing bundleconfig.json
Bundler: Done processing bundleconfig.json
WebApplication8 -> c:\WebApplication8\bin\Debug\netcoreapp1.1\WebApplication8.dll

Build succeeded.
0 Warning(s)
0 Error(s)

...even from the command line with "dotnet build." It's all integrated.

This is nice for VS Code or users of other editors. Here's how it would work entirely from the command prompt:

$ dotnet new mvc
$ dotnet add package BuildBundlerMinifier
$ dotnet restore
$ dotnet run

Advanced: Using Gulp to handle Bundling/Minifying

If you outgrow this bundler or just like Gulp, you can right click and Convert to Gulp!

Convert to Gulp

Now you'll get a gulpfile.js that uses the bundleconfig.json and you've got full control:

gulpfile.js

And during the conversion you'll get the npm packages you need to do the work automatically:

npm and bower

I've found this to be a good balance that can get quickly productive with a project that gets bundling without npm/node, but I can easily grow to a larger, more npm/bower/gulp-driven front-end developer-friendly app.


Sponsor: Did you know VSTS can integrate closely with Octopus Deploy? Join Damian Brady and Brian A. Randell as they show you how to automate deployments from VSTS to Octopus Deploy, and demo the new VSTS Octopus Deploy dashboard widget. Register now!


© 2017 Scott Hanselman. All rights reserved.
     

The week in .NET – Happy birthday .NET with Mads Torgersen, Coypu

$
0
0

Previous posts:

On .NET

This week, we’ll have Sidarth Gupta and Hong-Seok Kim from Samsung on the show to talk about their Tizen OS and its support for .NET Core. The show won’t be live this week, because of the time difference with Korea, but you may still send us your questions on Gitter’s dotnet/home channel and on Twitter. Please use the #onnet tag.

Happy birthday .NET!

Mads Torgersen is the Principal Program Manager for the C# Language. He maintains the language specification and runs the language design process for C# in the open at https://github.com/dotnet/csharplang. We caught up with Mads at the .NET 15th anniversary party where he shares his thoughts on the past, present and future of .NET.

Package of the week: Coypu

Coypu is a robust .NET wrapper for browser automation tools such as Selenium WebDriver, that eases automating ajax-heavy websites and reduces coupling to the HTML, CSS & JS. It implements an intuitive DSL for interacting with the browser in the way a human being would.

Meetups of the week: .NET Core Tour in Poland

Łukasz Pyrzyk and Piotr Gankiewicz are going on a three months tour across Poland to present live demos of ASP.NET Core and .NET Core. The tour begins today in Wrocław, and will end in June. Check out the planning on Łukasz’s blog and register!

.NET Tour in Poland

.NET

ASP.NET

C#

F#

New F# Language Suggestions:

Check out F# Weekly for more great content from the F# community.

Xamarin

UWP

Azure

Game development

And this is it for this week!

Contribute to the week in .NET

As always, this weekly post couldn’t exist without community contributions, and I’d like to thank all those who sent links and tips. The F# section is provided by Phillip Carter, the gaming section by Stacey Haffner, and the Xamarin section by Dan Rigby, and the UWP section by Michael Crump.

You can participate too. Did you write a great blog post, or just read one? Do you want everyone to know about an amazing new contribution or a useful library? Did you make or play a great game built on .NET?
We’d love to hear from you, and feature your contributions on future posts:

This week’s post (and future posts) also contains news I first read on The ASP.NET Community Standup, on Weekly Xamarin, on F# weekly, and on Chris Alcock’s The Morning Brew.

Apply Now for Microsoft’s Go Mobile Tech Workshops

$
0
0

This is your opportunity to bring Microsoft engineering experts to discuss app development and architecture best practices with your team 1:1 

We’re excited to announce that the Microsoft engineering team is offering a limited number of technical sessions to help your team build better mobile apps faster. The Go Mobile Tech Workshops are 3 hour sessions dedicated to your team, covering everything from your technology stack and architecture to the latest in Visual Studio 2017, Azure, and DevOps best practices.  

Sign-up now

What’s in it for you

  • Dedicated time with Microsoft technical experts to help you analyze your technology stack and application development practices.
  • Common patterns, architectures, and best practices for mobile to help you go faster and avoid common pitfalls.
  • Q&A with the engineering team to address your technical questions.

Don’t miss out—apply for a workshop today!

Joseph Hill, Principal Director PM, Mobile Development Tools

Prior to joining Microsoft, Joseph was VP of Developer Relations and Co-Founder at Xamarin.  Joseph has been an active participant and contributor in the open source .NET developer community since 2003. In January 2008, Joseph began working with Miguel de Icaza as Product Manager for his Mono efforts, ultimately driving the product development and marketing efforts to launch Xamarin’s commercial products.

Visual Studio 2017 can automatically recommend NuGet packages for unknown types

$
0
0

There's a great feature in Visual Studio 2015.3 and Visual Studio 2017 that is turned off by default. It does use about ~10 megs of memory but it makes me so happy that I turn it on.

It's under C# | Advanced in Tools Options. Or you can just type "Advanced" in the Quick Launch Bar (via Ctrl+Q if you like) to jump there.

I turn on

I turn on "Suggest usings for types in NuGet packages" and "Suggest usings for types in reference assemblies."

For example, if I am typing some code and start referencing a Type that isn't in my project but could be...you know how sometimes you just need a using statement to bring in a namespace? In this Web App, I already have Json.NET so it recommends a using statement to bring it into scope.

Can't find JSON

But in this Console App, I have no packages beyond the defaults. When I start using a type like JObject from a popular NuGet, Visual Studio can offer to install Json.NET for me!

Find and install latest version

Or another example:

XmlDocument

And then I can immediately continue typing with intellisense. If I know what I'm doing, I can bring in something like this without ever using the mouse or leaving the line.

JObject is now usable

Good stuff! 


Sponsor: Check out JetBrains Rider: a new cross-platform .NET IDE. Edit, refactor, test, build and debug ASP.NET, .NET Framework, .NET Core, or Unity applications. Learn more and get access to early builds!



© 2017 Scott Hanselman. All rights reserved.
     

Cows can be so silly

$
0
0

Last week, we had some visitors from Redmond visiting us in North Carolina.  I invited a few of them out to my house for dinner – they were interested in seeing this farm that I talk about from time to time.

After we got to my house I herded everyone into my car to drive up to the barn.  As we got to the top of the hill, I could tell something wasn’t right.  I saw a pile of hay and a bunch of cows (yearlings) but no hay ring.  The person sitting next to me in the car, apparently, could see by the look on my face that something was wrong and asked me about it.  I told them I wasn’t sure but this isn’t the way it’s supposed to be.

We got out of the car and I surveyed the field and, immediately, I knew what it was.  Sure enough, half way down the field was one of our calves with the hay ring stuck on its back hips.  Jeez.  Younger animals will go through the holes in the hay ring to stand inside it.  If they are big enough, when they try to get out they will sometimes get the hay ring stuck on their rear hip bones.

You may remember a story from some years ago about how I almost ended up in a pond because I got into the middle of the hay ring to try to get it off a cow and the cow took off running, pulling the hay ring and me with it.  I’ve learned from that lesson.  I did not make the mistake of climbing into the hay ring and, instead, stood beside it and lifted it just high enough for the cow to get its hips out.  Fortunately, it only took a few minutes and the cow stayed reasonably calm.  All was restored to normalcy and no harm was done.  But I do have to wonder how long that cow walked around that field dragging the hay ring 🙂  It couldn’t have been more than a few hours (because someone checks on them a couple of times a day, at least), but it could have been a few hours 🙂

Here’s a picture Aaron took of me rolling the hay ring back after I got it off the cow.  Unfortunately, we didn’t get a picture of the hay ring stuck on the cow – I was too focused on safely getting it off 🙂

hayring2

You can tell from the picture it was a beautiful day – it was cold, but beautiful.

I guess my friends, at least, have a new appreciation for how odd my life can be 🙂

Brian

VSTest task dons a new avatar – testing with unified agents and phases

$
0
0

Visual Studio Test (VSTest) and the Run Functional Test (RFT) tasks are used widely for continuous testing with Team Build and Release Management. As we thought about how test execution in the pipeline should evolve the guiding principles were to ensure that test execution in the pipeline is fast and reliable for all types of tests, be it unit tests (native MSTest as well as 3rd party) or functional tests – both UI and non-UI. Build and Release agents are already unified, so we were wondering if we could have Test Agent integrated as well  and get a ‘single automation agent to rule’ 🙂

So, what advantages does the unified agents work bring?

You can leverage the agent pool for all purposes – build, release and test.

  • Reusable agents means that you no longer need dedicated machines (as required by RFT task). Admins can setup a reusable pool and managing machines becomes easier.
  • You can use the unified agent for single machine as well multi-machine distributed execution.
    • VSTest task has been running on the agent, so single machine was always covered.
    • Distributed execution provided by RFT on remote machines using the Test Agent now comes to the unified agent, so you no longer need the ‘Deploy Test Agent’ like step.
    • ‘Deploy Test Agent’ was based on WinRM and WinRM had it’s own set of limitations, making the whole thing a steep learning curve. So yay, another complexity gone.
    • Since all execution is now local to the automation agent and phases downloads the artifacts automatically to the machines, you also don’t need ‘copy files’ tasks that were required to copy test assemblies and their dependencies when running tests remotely using RFT.

Let us get to the how-to now. The capabilities discussed here apply to the Visual Studio Test v2 (preview) task, so make sure you switch the task versions.

v2task

 

The first one is getting to know phases. When you create a release definition, you can add different types of phases – agent phase, deployment group phase or a server phase. You can add multiple phases of different types, in the order you need them to build your pipeline. Lets take a closer look at the agent phase settings.agentphasesettings‘Run on multiple agents in parallel’ provides 3 options:

  1. None– this means that a single agent from the specified queue will be allocated to this phase. This is the default and all tasks in the phase will run on that agent. When VSTest task runs, it runs exactly how it runs today – no change. You get a single agent test execution. So if I wanted to deploy an Azure web-app and run a small number of quick tests on it (for which a single agent suffices), along with some pre and post test setup/cleanup activities, I can model my environment as follows:
  2. Multi-agent – this mode means that multiple agents will get allocated to the phase. You can specify the number of agents to be allocated from the pool and the set of tasks in that phase will be run across all agents.

multiagent

VSTest task in this mode is special. It recognizes that it’s a multi-agent phase and runs tests in a distributed manner across the allocated agents. Since other tasks are run across all agents, any pre and post test steps I may want to do, also run equally on all the agents – so all the agents are prepped and cleaned up in a consistent manner. Test execution also does not require all agents to be available at the same time. If some agents are busy with another release or build, the phase can still start with the available number of agents that match the demand and test execution starts. As additional agents become available, they can pick up any remaining tests that have not been run yet. Here’s a screenshot of logs from my multi-agent test run, where some tests have failed.

multiagenttestrun

Artifacts are automatically downloaded when the phase starts, so my test assemblies and other files are already on the agent and I don’t need a copy files task.

So now if I want to publish an Azure web-app and run a large set of tests with fast test execution, I will model my Release environment as 2 phases – 1 being the deploy phase (runs on a single agent – I don’t want multiple agents to deploy the same app concurrently :-)) and a test phase that uses multi-agent mode to do test distribution. This also means that I can use different agent queues for the 2 phases, allowing me to manage agents for different purposes separately if I so choose.

distributedtests

3. Multi-config – this mode is driven by ‘multipliers’ pretty much the same way as a multi-config build is. Define the multipliers as variables and based on the values for these variables, the various configurations are run. In the case of Build, typically you would use BuildPlatform and BuildConfiguration as multipliers. Let us see how to apply this to testing. Same example as before – I want to deploy a web-app to Azure and run cross-browser tests on IE and Firefox. So I will model my environment as 2 phases – 1 deploy phase and the second is test phase. multiconfigThe test phase is setup as multi-config using ‘Browser’ variable, that has the values IE and Firefox. My phase will now run using these configs (2 in this case), 1 agent gets assigned a config and the appropriate config values are available for tasks to use.

multipliers

In my case, I want to use the Browser value to instantiate the right browser in my tests, so I will pass them as Test Run Parameters and access the value using TestContext in the test code. I will also use this value to title my test runs appropriately so that if a test fails in a particular config, I can easily figure that based on which run it came from.

multiconfigtasksettings

Here’s what the execution would look like:

multiconfiglogs

That’s all for today’s post. Give the VSTest v2 task a spin and let us know your feedback. Leave comments below or reach me at pbora AT microsoft DOT com.

FAQ

  1. How do I do this with Build?
    • The phases capability is currently available only in Release Management. It will become available in Build in a few sprints.
  2. Does VSTest v1 task behave the same way as the v2 task?
    • No, the v1 task does not do distribution. In the single agent (default, no parallelism) setting, the task will run as the way it has been running today. In the multi-config and multi-agent scenarios, it will get replicated on the agents, like all other tasks.
  3. What is needed to run UI tests?
    • To run UI tests, be sure to run agent in interactive mode. Agents set to run as service cannot run UI tests. Interactive agents in their current form will go down if the machine reboots for any reason. Enhancing the agent to survive reboots in interactive mode is being worked on. Also disable screensaver and unlock the machine so that UI actions in the test don’t get blocked. Automatic configuration of agents to do this is in the works.
  4. Can I run UI tests on the hosted agents?
    • No, running UI tests on the hosted agents is not possible currently.
  5. What does the ‘Test mix contain UI tests’ checkbox do?
    • Currently, it’s there only to serve as a reminder to run agents interactively if you are running UI tests. 🙂 If you are using an agent pool with a mix of interactive and ‘running as service’ agents, you may also want to add an ‘Interactive’ capability to your agents and use that demand in your test phase to pick the set of agents that can run UI tests.
  6. In multi-config mode, do I get distribution of tests as well?
    • No, multi-config mode assigns only one agent per config.
  7. How do I map the config in multi-config to my Test Configurations in TCM?
    • Currently this is not possible.
  8. How else can I use multi-config?
    • This mode can be used whenever you need multiple agents to do parallel jobs. For some other examples, refer the docs.
  9. Has the Run Functional Tests task changed also?
    • No, the Run Functional Tests (RFT) task has not changed. If you are using RFT task, you DO need the ‘Deploy Test Agent’ step. Please note that since tasks get replicated in the multi-agent and multi-config mode, using Run Functional Tests task in that mode will lead to undesirable effects.
  10. Do I need to install Visual Studio on all the machines to use the VSTest v2 task?
    • Currently, yes. We are looking at alternate means to run tests without needing Visual Studio on the agent, so that you can create a separate pool of agents for testing purposes.
  11. I am using my own test runner (not VSTest) in the pipeline. What happens to it?
    • In the multi-agent and multi-config mode, the task will get replicated on each of the agents. You can leverage the multi-config mode to partition your tests on different configs using the config variable (e.g., if you have a config variable called Platform that takes values of x86 and x64, you can run the two sets of tests on 2 agents in parallel by referring to your test assemblies using ‘**\$(Platform)\*test*.dll’
  12. How does the VSTest v2 task run on Deployment Groups?
    • Yes, the VSTest v2 task can be used to run on Deployment groups as well. If you have scenarios that necessitates running tests on machines in the deployment group where the app is deployed, you can use the VSTest v2 task. If multiple machines are selected (say, using tags) in the ‘Run on Deployment Group’ phase, the tests will get replicated on each of the machines.

Command Line: Using dotnet watch test for continuous testing with .NET Core 1.0 and XUnit.net

$
0
0

I've installed .NET Core 1.0 on my machine. Let's see if I can get a class library and tests running and compiling automatically using only the command line. (Yes, some of you are freaked out by my (and other folks') appreciation of a nice, terse command line. Don't worry. You can do all this with a mouse if you want. I'm just enjoying the CLI.

NOTE: This is considerably updated from the project.json version in 2016.

First, I installed from http://dot.net/core. This should all work on Windows, Mac, or Linux.

C:\> md testexample & cd testexample

C:\testexample> dotnet new sln
Content generation time: 33.0582 ms
The template "Solution File" created successfully.

C:\testexample> dotnet new classlib -n mylibrary -o mylibrary
Content generation time: 40.5442 ms
The template "Class library" created successfully.

C:\testexample> dotnet new xunit -n mytests -o mytests
Content generation time: 87.5115 ms
The template "xUnit Test Project" created successfully.

C:\testexample> dotnet sln add mylibrary\mylibrary.csproj
Project `mylibrary\mylibrary.csproj` added to the solution.

C:\testexample> dotnet sln add mytests\mytests.csproj
Project `mytests\mytests.csproj` added to the solution.

C:\testexample> cd mytests

C:\testexample\mytests> dotnet add reference ..\mylibrary\mylibrary.csproj
Reference `..\mylibrary\mylibrary.csproj` added to the project.

C:\testexample\mytests> cd ..

C:\testexample> dotnet restore
Restoring packages for C:\Users\scott\Desktop\testexample\mytests\mytests.csproj...
Restoring packages for C:\Users\scott\Desktop\testexample\mylibrary\mylibrary.csproj...
Restore completed in 586.73 ms for C:\Users\scott\Desktop\testexample\mylibrary\mylibrary.csproj.
Installing System.Diagnostics.TextWriterTraceListener 4.0.0.
...SNIP...
Installing Microsoft.NET.Test.Sdk 15.0.0.
Installing xunit.runner.visualstudio 2.2.0.
Installing xunit 2.2.0.
Generating MSBuild file C:\Users\scott\Desktop\testexample\mytests\obj\mytests.csproj.nuget.g.props.
Generating MSBuild file C:\Users\scott\Desktop\testexample\mytests\obj\mytests.csproj.nuget.g.targets.
Writing lock file to disk. Path: C:\Users\scott\Desktop\testexample\mytests\obj\project.assets.json
Installed:
16 package(s) to C:\Users\scott\Desktop\testexample\mytests\mytests.csproj

C:\testexample> cd mytests & dotnet test

Build started, please wait...
Build completed.

Test run for C:\testexample\mytests\bin\Debug\netcoreapp1.1\mytests.dll(.NETCoreApp,Version=v1.1)
Microsoft (R) Test Execution Command Line Tool Version 15.0.0.0
Copyright (c) Microsoft Corporation. All rights reserved.

Starting test execution, please wait...
[xUnit.net 00:00:00.5539676] Discovering: mytests
[xUnit.net 00:00:00.6867799] Discovered: mytests
[xUnit.net 00:00:00.7341661] Starting: mytests
[xUnit.net 00:00:00.8691063] Finished: mytests

Total tests: 1. Passed: 1. Failed: 0. Skipped: 0.
Test Run Successful.
Test execution time: 1.8329 Seconds

Of course, I'm testing nothing yet but pretend there's a test in the tests.cs and something it's testing (that's why I added a reference) in the library.cs, OK?

Now I want to have my project build and tests run automatically as I make changes to the code. I can't "dotnet add tool" yet so I'll add this line to my test's project file:



Like this:

" style="border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; margin: 0px 0px 0px 5px; display: inline; padding-right: 0px; border-top-width: 0px" border="0" alt="Adding " src="https://www.hanselman.com/blog/content/binary/Windows-Live-Writer/785ac31a1e8a_1227F/image_a184785b-052e-4e29-ab4b-e7f16b56b808.png" width="1001" height="525">

Then I just dotnet restore to bring in the tool.

NOTE: There's a color bug using only cmd.exe so on "DOS" you'll see some ANSI chars. That should be fixed in a minor release soon - the PR is in and waiting. On bash or PowerShell things look fin.

In this screenshot, you can see as I make changes to my test and hit save, the DotNetWatcher Tool sees the change and restarts my app, recompiles, and re-runs the tests.

Test Run Successful

All this was done from the command line. I made a solution file, made a library project and a test project, made the test project reference the library, then built and ran the tests. If I could add the tool from the command line I wouldn't have had to manually touch the project file at all.

Again, to be sure, all this is stuff you can (and do) do in Visual Studio manually all the time. But I'll race you anytime. ;)


Sponsor: Check out JetBrains Rider: a new cross-platform .NET IDE. Edit, refactor, test, build and debug ASP.NET, .NET Framework, .NET Core, or Unity applications. Learn more and get access to early builds!


© 2017 Scott Hanselman. All rights reserved.
     

TypeScript’s New Release Cadence

$
0
0

One of the things we love about the TypeScript community is the enthusiasm around new features and rapid adoption of new TypeScript releases. Because of this, we have been focusing on increasing the velocity and consistency of TypeScript releases so that you can get your hands on the latest features even more quickly and predictably. This new release cadence has been mostly great, but there has been some confusion on when and how to get the latest TypeScript version. There have also been questions regarding availability of TypeScript in Visual Studio 2017. This blog post aims to clarify our intentions and our general plan for shipping TypeScript in the future, including shipping as a part of Visual Studio and Visual Studio Code.

New release cadence

With TypeScript 2.0 and earlier releases, we didn’t bother keeping a predictable release schedule. New versions were ready when they were ready, and we kept working on a release until it had all the features we wanted to be merged in.

This was nice in that each TypeScript release felt large and impactful, but came with the downside of small fixes getting gated behind significant changes, and seemingly random amounts of time between releases. Furthermore, the scope of impact wasn’t just limited to TypeScripr users. VS Code takes advantage of the TypeScript language service to power its JavaScript editing experience as well. This meant that any bug fixes for VS Code, for both TypeScript and JavaScript, would have to wait for a full release to be completed before shipping. Because VS Code ships every month, it sometimes took several VS Code releases before even minor bugs could be fixed. To both address the needs of VS Code and to get features out to the TypeScript community faster, we’ve moved to a monthly release cadence for TypeScript that mirrors the cadence adapted by Visual Studio Code.

Going forward, TypeScript releases will adhere to the following principles:

  • Release a full feature release every two months (e.g. 2.1, 2.2, etc.)
  • Publish at least one TypeScript update to npm every month (either patch or feature releases)
  • Features that aren’t complete by release time are deferred to the next release
  • TypeScript’s monthly release should come ~1 week before, and be included in, a VS Code release
  • Other editors can adopt the new TypeScript version during their next available update

The following diagram may help visualize the new cadence.

We believe that following these principles will benefit everyone in the TypeScript community.

TypeScript updates to Visual Studio

Supporting the latest Typescript release in Visual Studio has been one of the goals that we’ve been working on as a team. However, when Visual Studio 2017 RTM released a few weeks back, we were not able to include the latest TS version (v2.2) with it. Instead, Visual Studio 2017 currently comes with built-in support for Typescript v2.1.5.

With the changing cadence of TypeScript releases, we could not fully align the TypeScript v2.2 release with Visual Studio 2017. Given some key changes that have gone into the new setup authoring process for Visual Studio 2017, we need to do additional work to ensure that TypeScript releases can be applied to Visual Studio 2017 at a faster cadence as users might be used to in Visual Studio 2015 and VS Code.

We’ve heard feedback from several users about their need to move to TypeScript v2.2 in Visual Studio 2017 and understand the confusion and pain this has caused. As a team, we’re actively working on the problem and hope to have a fix available soon. We’ll keep the community updated as we make progress. Once implemented, developers will have full flexibility to update as soon as a new version of TypeScript is available. We apologize for the confusion and want to assure you that fixing this issue is a top priority.

Drop us a line

The great part about being an open source project is that we can make changes, get immediate feedback from the community, and quickly improve in the future. As such, we greatly appreciate your enthusiasm and would love to hear your feedback.

As always, you can find us on GitHub, Twitter, and Gitter.

Monitoring build resources with the TFS 2017 management pack

$
0
0

The Microsoft System Center Management Pack for Visual Studio Team Foundation Server 2017 (what a name!) has been available for about a month now. One important change to note in this version of the management pack is that it no longer supports monitoring of build resources. But don’t worry – you can still easily monitor these resources using other capabilities of System Center.

Team Foundation Server Management Packs for System Center have handled build resources (XAML controllers and agents; Build/Release agents) in various ways over the years.

Early versions discovered build resources by starting from TFS deployments, enumerating build resources for those deployments, and then reaching out to them. This had some advantages, in that it was easy to get all build machines monitored without having to explicitly enumerate them. It also had some disadvantages, however, in that all build machines had to be monitored in order for any monitoring to work.

Later, we moved to an approach where build resources were discovered and monitored independently by System Center agents running on the machines where the build resources lived. This made it possible to monitor a subset of build resources by not installing management agents on the machines that did not need monitoring. Discovering build resources locally required using things like registry keys, however, which then had to be created by our various agents/controllers. This conflicted with our progress toward extremely lightweight agent installation/configuration, and the TFS 2015 management pack couldn’t discover agents running interactively. (Or agents on non-Windows machines, for that matter.)

The registry keys used to discover TFS 2015 build agents were versioned as well, which was going to create a problem moving forward with monitoring TFS deployments across multiple versions from the same System Center deployment.

In TFS 2017, we decided to go a different route with the management pack and abandon our attempts to monitor build resources. Partly this was because of the effort involved in properly monitoring all the different build resource types we support from TFS 2017 (which include XAML controllers and agents from 2010, 2013, and 2015; as well as our new agents from 2015 and 2017, which can run on Windows, OSX, and various Linux OSes). And partly this was because our build monitoring has never added any real value beyond the existing monitoring capabilities available within System Center.

System Center has built-in capabilities to monitor machine availability, processes and Windows Services on Windows computers, and processes on Linux computers. Our recommendation moving forward, for teams who wish to monitor their build resources in addition to their TFS deployments, is to do the following:

  1. Add all the machines where your critical build resources are running to the list of machines monitored by your System Center deployment. This will ensure that you notice when the machines themselves get into trouble, go offline, etc.
  2. For your critical XAML build resources, create a Windows Service monitor for the appropriate service name – TFSBuildServiceHost.2013, for example. Windows Service monitors are nice in that they only monitor those services that are set to start automatically when Windows starts, meaning that you can choose to apply this monitor to all machines in your System Center deployment without worrying that it will start generating alerts on machines that are not TFS XAML build machines.
  3. For your critical Build/Release resources, create process monitors for the appropriate OSes and agent versions – Agent.Listener.exe, for example, for TFS 2017 Windows agents. Process monitors are a bit trickier than Windows Service monitors in that they will apply to every machine in the group you select. As such, your best bet for these monitors is to create a group that includes all and only your critical Build/Release machines. This can be done either by explicitly specifying these machines, or by using naming conventions for your build resources in combination with dynamic rules in your System Center group definition.

We believe this combination of monitors will do as good a job or better of monitoring your TFS build resources for TFS 2017 deployments. Using this approach, you can monitor agents running interactively, agents running on Linux machines, etc. You can even get alerts if CPU or Memory consumption by the agent process or service exceeds a custom threshold. None of this has ever been supported by the TFS management pack monitoring.

Please let us know if you have feedback or encounter issues using this approach to monitor your TFS 2017 build resources.

The week in .NET – On .NET with Sidharth Gupta on Tizen, Happy birthday .NET with Bertrand Le Roy, JSON.NET 10, Gunnar Peipman

$
0
0

Previous posts:

On .NET

Last week, we spoke with Sidharth Gupta from Samsung about Tizen. Tizen is Samsung’s open-source OS that runs on TVs, watches, phones, and other devices. The development platform for Tizen is built on .NET Core and Xamarin Forms.

This week, we’ll talk about SonarLint with Tamás Vajk. We’ll take questions on Gitter, on the dotnet/home channel and on Twitter. Please use the #onnet tag. It’s OK to start sending us questions in advance if you can’t do it live during the show.

Happy birthday .NET!

Bertrand Le Roy started using .NET with the first public betas, then proceeded to write a CMS with it. That’s when he moved to the US and joined the ASP.NET team that was working on ASP.NET 2.0 at the time. He’s worked on ASP.NET Ajax (including UpdatePanel, yes), co-founded the Orchard CMS project, and is now working as a Program Manager on .NET Core. He sometimes speaks of himself in the third person.

Package of the week: JSON.NET 10

I’ve featured JSON.NET before, and it’s the #1 package on NuGet with more than 50 million downloads. Version 10 is out, with new features that make it a particularly exciting release. Specifically, the library now has full async support.

Download JSON.NET 10 on NuGet.org.

Blogger of the week: Gunnar Peipman

Gunnar Peipman has had at least one post a week featured here for quite a while, and this week is no exception, as you’ll find three of his posts in the ASP.NET, C#, and Azure sections. His posts are always very focused and immediately useful. Check out his blog!

Meetups of the week: game development with Unity for Windows 10 in NYC

Tonight at 6PM at the Microsoft Reactor in NYC, the Microsoft makers and app developers group holds a meeting where you’ll learn about game development on Windows 10 using Unity.

.NET

ASP.NET

C#

F#

New F# Language Suggestions:

Check out F# Weekly for more great content from the F# community.

Xamarin

Azure

UWP

Data

Game Development

And this is it for this week!

Contribute to the week in .NET

As always, this weekly post couldn’t exist without community contributions, and I’d like to thank all those who sent links and tips. The F# section is provided by Phillip Carter, the gaming section by Stacey Haffner, and the Xamarin section by Dan Rigby, and the UWP section by Michael Crump.

You can participate too. Did you write a great blog post, or just read one? Do you want everyone to know about an amazing new contribution or a useful library? Did you make or play a great game built on .NET?
We’d love to hear from you, and feature your contributions on future posts:

This week’s post (and future posts) also contains news I first read on The ASP.NET Community Standup, on Weekly Xamarin, on F# weekly, and on Chris Alcock’s The Morning Brew.

Open sourcing the MSTest Test Framework

$
0
0

A couple of months ago I blogged about open sourcing the VS Test platform.  In that post, I talked about the numerous test frameworks that it supports, on of the most popular ones being MSTest.  I also foreshadowed our plan to also open source MSTest V2.  Today I’m happy to announce that we have open sourced MSTest V2 under the MIT license.  This open source announcement means that the community now has a fully supported, fully open source, fully cross-platform implementation of the MSTest test framework with which to write tests targeting .NET Framework, .NET Core and ASP.NET Core on Windows, Linux, and Mac. 

Here are the public repositories on GitHub where the project is hosted: 

The repos include the complete implementation of the test framework and its adapter, the templates, and the Create Unit Tests and Create IntelliTest wizard extensions.  These are fully open and ready to accept contributions.  Over the next several weeks and months we will continue to transfer more source and documentation into the repositories and likewise make it open for contributions. 

The “MSTest V2” journey

We began the MSTest V2 journey with the intent of providing users of the MSTest test framework a viable path going forward, and the post MSTest V2 – Now and Ahead summarizes the rationale and the investments made thus far.  Thank you for all the issues you reported and your feedback; we have addressed them as fast as we can, refreshing the bits on NuGet at a feverish pace. 

One prominent piece of feedback that emerged along the way was to make MSTest framework open source.  With this announcement we have addressed that request. 

Our commitment to the MSTest test framework community is unwavering.  Going forward, we will engage in transparent development.  Towards that, we will share, make visible, and collaborate on issues, implementation and our roadmap.  We look forward to your continued support and participation.

Thank you,

Brian

Bing Launches an iMessage Extension

$
0
0

With the introduction of the Bing iMessage Extension, people can express themselves with GIFs, search and easily share places, movies, and more from the web, without leaving the conversation. To get started, simply get the Bing app for iPhone and enable the Bing iMessage Extension through iMessage.

Bing iMessage Extension

Express Yourself with Hilarious GIFs


Share What You’ve Previously Found or Find Something New


Bing iMessage - Share what you've foundBing iMessage - Share what you've foundBing iMessage - Share what you've found

Make Plans for a Group Movie and Meal Out

While sharing a Bing link was a good way to pass along content that users had common interest in, surfing back and forth between messaging friends and sifting through a multitude of movies or restaurants is a hassle. The Bing iMessage Extension allows you to share a restaurant or movie card directly so it’s easier and quicker to make plans.

Easily check out what’s in theaters with a group before committing.

Bing iMessage - Make plansBing iMessage - Make plansBing iMessage - Make plansBing iMessage - Make plans

Search and then share multiple restaurants with a group of friends to help make a decision.

Bing iMessage - search and share restaurantsBing iMessage - search and share restaurantsBing iMessage - search and share restaurants

To make sure you have access to the new Bing iMessage Extension, download the Bing app.

- The Bing Team

Viewing all 10804 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>