{"id":39043,"date":"2019-04-23T13:13:10","date_gmt":"2019-04-23T18:13:10","guid":{"rendered":"https:\/\/devblogs.microsoft.com\/appcenter\/?p=39043"},"modified":"2019-04-23T13:19:36","modified_gmt":"2019-04-23T18:19:36","slug":"faster-android-tests-and-nunit-3","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/appcenter\/faster-android-tests-and-nunit-3\/","title":{"rendered":"Faster Android Tests and NUnit 3"},"content":{"rendered":"<p><span data-contrast=\"auto\">Xamarin.UITest<\/span><span data-contrast=\"auto\">\u00a0is a\u00a0<\/span><span data-contrast=\"auto\">popular\u00a0<\/span><span data-contrast=\"auto\">C# testing framework which works great with both native and cross-platform apps, using frameworks like Xamarin. Today I\u2019m happy to announce two updates we have made to the\u00a0<\/span><span data-contrast=\"auto\">UITest<\/span><span data-contrast=\"auto\">\u00a0framework, in the form of a performance boost for cloud tests and adding\u00a0<\/span><span data-contrast=\"auto\">NUnit<\/span><span data-contrast=\"auto\">\u00a03 support both locally and in the cloud.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<h4 aria-level=\"1\"><span data-contrast=\"none\">Speed Updates\u00a0<\/span><span data-contrast=\"none\">for<\/span><span data-contrast=\"none\">\u00a0<\/span><span data-contrast=\"none\">Faster\u00a0<\/span><span data-contrast=\"none\">Screenshots<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:0,&quot;335559740&quot;:259}\">\u00a0<\/span><\/h4>\n<p><span data-contrast=\"auto\">Along with access\u00a0<\/span><span data-contrast=\"auto\">to<\/span><span data-contrast=\"auto\">\u00a0additional devices to run tests, an additional benefit\u00a0<\/span><span data-contrast=\"auto\">to<\/span><span data-contrast=\"auto\">\u00a0using\u00a0<\/span><span data-contrast=\"auto\">Visual Studio\u00a0<\/span><span data-contrast=\"auto\">App\u00a0<\/span><span data-contrast=\"auto\">Center\u2019s<\/span><span data-contrast=\"auto\">\u00a0device cloud is the ability to take screenshots during a test and see how your app\u00a0<\/span><span data-contrast=\"auto\">actually runs<\/span><span data-contrast=\"auto\">. This is a highly valuable secondary aspect to testing, ensuring images are render<\/span><span data-contrast=\"auto\">ed<\/span><span data-contrast=\"auto\">\u00a0correctly and troubleshooting visual issues that may not be reflected in a test. Taking screenshots does come with a cost however, as it takes additional time to take and process the image, causing test runs to take longer.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<p><img decoding=\"async\" class=\"aligncenter wp-image-39044 size-large\" src=\"https:\/\/devblogs.microsoft.com\/appcenter\/wp-content\/uploads\/sites\/3\/2019\/04\/test_cloud_run-1024x751.jpg\" alt=\"\" width=\"640\" height=\"469\" srcset=\"https:\/\/devblogs.microsoft.com\/appcenter\/wp-content\/uploads\/sites\/3\/2019\/04\/test_cloud_run-1024x751.jpg 1024w, https:\/\/devblogs.microsoft.com\/appcenter\/wp-content\/uploads\/sites\/3\/2019\/04\/test_cloud_run-300x220.jpg 300w, https:\/\/devblogs.microsoft.com\/appcenter\/wp-content\/uploads\/sites\/3\/2019\/04\/test_cloud_run-768x563.jpg 768w, https:\/\/devblogs.microsoft.com\/appcenter\/wp-content\/uploads\/sites\/3\/2019\/04\/test_cloud_run.jpg 2048w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun CommentStart SCXW143031527 BCX0\">The<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun SCXW143031527 BCX0\">\u00a0performance improvements we have done include a rework of the foundation for\u00a0<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"SpellingError SCXW143031527 BCX0\">Xamarin.UITest<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun SCXW143031527 BCX0\">\u00a0on Android, now taking\u00a0<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun CommentStart SCXW143031527 BCX0\">screenshots\u00a0<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun SCXW143031527 BCX0\">in App\u00a0<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"SpellingError SCXW143031527 BCX0\">Center<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun SCXW143031527 BCX0\">\u00a0<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun SCXW143031527 BCX0\">has never been faster. The best part is that you do not have to change any code in your tests, just update to the\u00a0<\/span><\/span><a class=\"Hyperlink SCXW143031527 BCX0\" href=\"https:\/\/www.nuget.org\/packages\/Xamarin.UITest\/3.0.0-dev1\" target=\"_blank\" rel=\"noopener noreferrer\"><span class=\"TextRun Underlined SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"none\"><span class=\"NormalTextRun SCXW143031527 BCX0\">latest NuGet packages<\/span><\/span><\/a><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun SCXW143031527 BCX0\">\u00a0and everything works out of the box. To illustrate this improvement, the screenshot service has been cut from taking 6 seconds per screenshot down to 4 seconds for a whooping 32 screenshots. That is enough pictures to compile an animated gif in less time than it took for one picture before.\u00a0<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun SCXW143031527 BCX0\">How does this impact actual test\u00a0<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"ContextualSpellingAndGrammarError SCXW143031527 BCX0\">runs<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun SCXW143031527 BCX0\">\u00a0you may ask?<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun SCXW143031527 BCX0\">\u00a0 A test suite we have\u00a0<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"ContextualSpellingAndGrammarError SCXW143031527 BCX0\">takes<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun SCXW143031527 BCX0\">\u00a092 screenshots and would finish in roughly 17 minutes in the old pipeline. It is now down to 2 minutes and 42 seconds for the exact same test suite using the latest updates.<\/span><\/span><span class=\"TextRun SCXW143031527 BCX0\" lang=\"EN-GB\" xml:lang=\"EN-GB\" data-contrast=\"auto\"><span class=\"NormalTextRun CommentStart SCXW143031527 BCX0\">\u00a0With those gains, we might even encourage you to take extra screenshots.<\/span><\/span><span class=\"EOP SCXW143031527 BCX0\" data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<h4 aria-level=\"1\"><span data-contrast=\"none\">NUnit<\/span><span data-contrast=\"none\">\u00a03 Support<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:0,&quot;335559740&quot;:259}\">\u00a0<\/span><\/h4>\n<p><span data-contrast=\"auto\">One of the challenges with software development is keeping dependencies up to date. It typically means additional time working on backend systems to ensure compatibility instead of working on new features. We face this on a regular basis as we strive to maintain support for the latest Android and iOS releases in our tools, which can sometimes be released with little to no notice. Since its launch, support for\u00a0<\/span><span data-contrast=\"auto\">NUnit<\/span><span data-contrast=\"auto\">\u00a03 with\u00a0<\/span><span data-contrast=\"auto\">Xamarin.UITest<\/span><span data-contrast=\"auto\">\u00a0has been a top request from customers and one we have wanted for some time. We are excited to report our latest update closes this gap. Now y<\/span><span data-contrast=\"auto\">ou can update your\u00a0<\/span><span data-contrast=\"auto\">NUnit<\/span><span data-contrast=\"auto\">\u00a0package along with\u00a0<\/span><span data-contrast=\"auto\">UITest<\/span><span data-contrast=\"auto\">\u00a0to the latest versions and run tests both locally and in App\u00a0<\/span><span data-contrast=\"auto\">Center<\/span><span data-contrast=\"auto\">, plus have access to the updates and fixes available in<\/span><span data-contrast=\"auto\">\u00a0<\/span><span data-contrast=\"auto\">NUnit<\/span><span data-contrast=\"auto\">\u00a0<\/span><span data-contrast=\"auto\">3.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<p><span data-contrast=\"auto\">We hope these updates help empower you to\u00a0<\/span><span data-contrast=\"auto\">s<\/span><span data-contrast=\"auto\">hip\u00a0<\/span><span data-contrast=\"auto\">your apps\u00a0<\/span><span data-contrast=\"auto\">with higher quality and confidence.\u00a0<\/span><span data-contrast=\"auto\">There has never been a better time to use App\u00a0<\/span><span data-contrast=\"auto\">Center<\/span><span data-contrast=\"auto\">. Sign-in to check out the latest updates, or\u00a0<\/span><a href=\"https:\/\/appcenter.ms\/signup?utm_source=AppCenter_blog&amp;utm_medium=Blog&amp;utm_campaign=NUnitpost&amp;utm_content=NUnit%20and%20Containerpost\"><span data-contrast=\"none\">sign up for free<\/span><\/a><span data-contrast=\"auto\">. We offer a free 30-day trial with our device cloud so go check it out. As always, we love to hear your feedback on what is working, and what you would like to see next. Reach out on twitter at @<\/span><span data-contrast=\"auto\">VSAppCenter<\/span><span data-contrast=\"auto\">\u00a0or <a href=\"http:\/\/aka.ms\/appcenterfeedback\">share your thoughts<\/a>. We look forward to hearing from you.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Xamarin.UITest\u00a0is a\u00a0popular\u00a0C# testing framework which works great with both native and cross-platform apps, using frameworks like Xamarin. Today I\u2019m happy to announce two updates we have made to the\u00a0UITest\u00a0framework, in the form of a performance boost for cloud tests and adding\u00a0NUnit\u00a03 support both locally and in the cloud.\u00a0<\/p>\n","protected":false},"author":54,"featured_media":39044,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[16],"tags":[],"class_list":["post-39043","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-mobiledev"],"acf":[],"blog_post_summary":"<p>Xamarin.UITest\u00a0is a\u00a0popular\u00a0C# testing framework which works great with both native and cross-platform apps, using frameworks like Xamarin. Today I\u2019m happy to announce two updates we have made to the\u00a0UITest\u00a0framework, in the form of a performance boost for cloud tests and adding\u00a0NUnit\u00a03 support both locally and in the cloud.\u00a0<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/appcenter\/wp-json\/wp\/v2\/posts\/39043","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/appcenter\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/appcenter\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/appcenter\/wp-json\/wp\/v2\/users\/54"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/appcenter\/wp-json\/wp\/v2\/comments?post=39043"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/appcenter\/wp-json\/wp\/v2\/posts\/39043\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/appcenter\/wp-json\/wp\/v2\/media\/39044"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/appcenter\/wp-json\/wp\/v2\/media?parent=39043"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/appcenter\/wp-json\/wp\/v2\/categories?post=39043"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/appcenter\/wp-json\/wp\/v2\/tags?post=39043"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}