Distribute Visual Studio Templates With Extensions Installer
Có thể bạn quan tâm

In the article Defining the Primary Problems that Test Automation Frameworks Solve we defined 40+ problems that test automation and frameworks should be able to solve. One of them was "Tests Speed Creation". In the last couple of publications, I showed you how you could speed up tests development through the use of project templates- Visual Studio Project Templates and .NET Core Project Templates.
Table of ContentsHistoryCreate VSIX Project TemplatePrerequisitesCreate VSIX ProjectInstall VSIX ExtensionUninstall VSIX ExtensionSummary.NET Core templates are easily distributed through publishing your NuGet packages to nuget.org. Here, I am going to show you how you can create a Visual Studio extensions installer for deploying your VS project and item templates. Later you can even publish them to Visual Studio marketplace.
History
While working on the Bellatrix project. We wanted to find ways to solve all 40+ problems in the best possible way. There were a couple of things that we had to address- distribute the getting-started projects (the so-called starter-kits) across all platforms and give people a fast way to create new Bellatrix test projects.
So, we used three different solutions for test project creation- Visual Studio project templates, .NET Core templates and custom made cross-platform templates. One of the ways for deploying the Bellatrix item and project templates was though Visual Studio extensions installers. Here I am going to share with you how you can use them too.
Create VSIX Project Template
Prerequisites
To find the VSIX project template, you must install the Visual Studio SDK.
1. Click Tools > Get Tools and Features...

2. From the Visual Studio Installer- install Visual Studio extension development

Create VSIX Project
1. Open New Project wizard
2. Create new empty VSIX project

3. Create desired item or project templates
For more information how to speed up tests writing check the last four articles in the series:
Standardize Page Objects with Visual Studio Item Templates
Create Multiple Files Page Objects with Visual Studio Item Templates
Speed up Automated Tests Writing with Visual Studio Project Templates
Speed up Automated Tests Writing with .NET Core Project Templates
The item and project templates are zip files.
4. Copy templates' zip files to the new project directory
5. Set Copy to Output Directory build action to Copy Always

6. Open source.extension.vsixmanifest file
7. Populate the information about the installer

8. Add the template's zip to Assets based on the type of the template.

8.1. In our case we choose Microsoft.VisualStudio.ProjectTemplate but you can pick a type for item template or snippet.
8.2. For the source browse to the file that we added to the project.

9. Set prerequisites for the VSIX installer- which version of Visual Studio will be supported. By default, the latest two versions are set.

10. Build your project
InstallVSIX Extension
After you build your project a new *.vsix file is generated in the bin folder. You double click on it, and the template will be installed on your machine.

You need to close all instances of Visual Studio or the installation will happen on the next restart of the tool.
After the extension is installed, you can create a new project from the extracted template.

Uninstall VSIX Extension
From Tool -> Extensions and Updates you can find all installed VSIX extensions. From there you can uninstall the extension.

Summary
In the article, we talked about how you can distribute the project/item templates you created among your peers. It is a convenient way for speed up tests writing and applying common team's coding/quality standards.
-50% coupon code: BELLATRIX50 -20% coupon code: BELLATRIX20 -20% coupon code: BELLATRIX20 -50% coupon code: BELLATRIX50 -20% coupon code: BELLATRIX20 -20% coupon code: BELLATRIX20 -30% coupon code: BELLATRIX30 Online Training
C# Java Non-functionalLEVEL: 1
C# Web Test Automation Fundamentals
Learn how to write and maintainable C# tests, understand test automation best practices and fundamental testing concepts.
Duration:20 hours
4 hour per day
LEVEL: 2
C# Test Automation Advanced
Learn how to use advanced C# features for creating tests. As well riting tests for WPF, WinForms, Universal using WinAppDriver and Android and iOS using Appium.
Duration:30 hours
4 hour per day
LEVEL: 3
C# Enterprise Test Automation Framework
Learn how to build projects structure as well essential design patterns. Handling environment configurations and framework extensibility. After discussing the core characteristics, we will start writing the core feature piece by piece. We will continuously elaborate on why we design the code the way it is and look into different designs and compare them. You will have exercises to finish a particular part or extend it further along with discussing design patterns and best practices in programming. Duration:30 hours
4 hour per day
LEVEL: 1
Java Web Test Automation Fundamentals
Learn how to write and maintainable Java tests, understand test automation best practices and fundamental testing concepts.
Duration:20 hours
4 hour per day
LEVEL: 2
Java Test Automation Advanced
Learn how to use advanced Java features for creating tests. As well riting tests for WPF, WinForms, Universal using WinAppDriver and Android and iOS using Appium.
Duration:30 hours
4 hour per day
LEVEL: 3
Java Enterprise Test Automation Framework
Learn how to build projects structure as well essential design patterns. Handling environment configurations and framework extensibility. After discussing the core characteristics, we will start writing the core feature piece by piece. We will continuously elaborate on why we design the code the way it is and look into different designs and compare them. You will have exercises to finish a particular part or extend it further along with discussing design patterns and best practices in programming. Duration:30 hours
4 hour per day
Performance Testing
Thе course is designed to teach QAs in tutorial format how to plan and conduct a performance test.
Duration:24 hours
8 hour per day
Related Articles
AutomationTools, Free Tools, Web Automation
UI Performance Analysis via Selenium WebDriver
The article from the series Automation Tools reviews different approaches to check the UI performance of web apps reusing your existing functional Selenium WebDriver tests. We will investigate the native ChromeDriver GetLog feature, the new Selenium 4 DevTools
AutomationTools, Free Tools
Quick Guide Bitbucket Pipelines on Running Selenium C# Tests
In this article from the series Automation Tools, I am going to guide you on how you can set up a Bitbucket Pipelines job for a Selenium C# project, run your Selenium tests, and display the report
AutomationTools, Free Tools, Java
Quick Guide Bitbucket Pipelines on Running Selenium Java Tests
In this article from the series Automation Tools, I am going to guide you on how you can set up a Bitbucket Pipelines job for a Selenium Java project, run your Selenium tests, and display the report
AutomationTools, Free Tools, Java
Quick Guide GitHub Actions on Running Selenium Java Tests
In this article from the series Automation Tools, I am going to guide you on how you can set up a GitHub Actions job for a Selenium Java project, run your Selenium tests, and display the
AutomationTools, Free Tools, Java
Healenium: Self-Healing Library for Selenium-based Automated Tests
In this article, we're going to review a library called Healenium. It is an AI-powered open-source library for improving the stability of Selenium-based tests, handling changes of updated web and mobile elements automatically. We're going to mention
AutomationTools
Software Management Automation in Automated Testing
In the newest article from the Automation Tools Series, we will talk about what software automation management is and how we can utilize it in our automated tests. At the end of the publication, you will
About the author
CTO and Co-founder of Automate The Planet Ltd, inventor of BELLATRIX Test Automation Framework, author of "Design Patterns for High-Quality Automated Tests: Clean Code for Bulletproof Tests" in C# and Java. Nowadays, he leads a team of passionate engineers helping companies succeed with their test automation. Additionally, he consults companies and leads automated testing trainings, writes books, and gives conference talks.
Search.Net TopicsWeb Automation
Development
Mobile Automation
Desktop Automation
API Automation
Design and Architecture
Automation Tools
Enterprise Test Framework
Testing practices
Special Editions
Fun Testing Stories
Java Topics
Web Automation
Mobile Automation
Desktop Automation
Design and Architecture
Testing practices
Special Editions
Fun Testing Stories
ReviewsFree tools
Commercial tools
Latest updates in your mailbox
Free tools
Commercial tools
Latest updates in your mailbox
Subscribe
Join our community
By continuing to browse, you consent to our use of cookies. To know more, please refer to our Privacy Policy. [Y]es, I agree Privacy Policy ClosePrivacy Overview
This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience. Necessary Necessary Always Enabled Necessary cookies are absolutely essential for the website to function properly. This category only includes cookies that ensures basic functionalities and security features of the website. These cookies do not store any personal information. Non-necessary Non-necessary Any cookies that may not be particularly necessary for the website to function and is used specifically to collect user personal data via analytics, ads, other embedded contents are termed as non-necessary cookies. It is mandatory to procure user consent prior to running these cookies on your website. SAVE & ACCEPTGet Instant Access to the latest Source Code
And join the Automate The Planet Community.
Get Full Source CodeYour Privacy is protected.
x
Subscribe
* indicates required Email Address * Name Subscribe for- Java
- C#
You can unsubscribe at any time by clicking the link in the footer of our emails. For information about our privacy practices, please visit our website.
Your Privacy is protected.
xTừ khóa » Vs 2019 Custom Template
-
Creating Custom Project And Item Templates - Visual Studio ...
-
Create Project Templates - Visual Studio (Windows) | Microsoft Docs
-
Customize Project And Item Templates - Visual Studio - Microsoft Docs
-
Project And Item Templates - Visual Studio (Windows) - Microsoft Docs
-
Add Or Edit Tags On Project Templates - Visual Studio (Windows)
-
VS2019 Custom Template Not Shown - Visual Studio - Stack Overflow
-
Custom Project Templates In Visual Studio 2019 - YouTube
-
Create Custom Project Templates In Visual Studio - Blogs - Canarys
-
Custom Project Templates Not Showing In Create New Project Window
-
Custom Project Templates Do Not Show Up In New Project Dialog
-
Start A Visual Studio Project With Templates - DotNetNuke
-
How To Create Project Templates And Extension For Visual Studio 2019
-
Karenpayneoregon/vs2019-custom-project-templates - GitHub
-
How To: Locate And Organize Project And Item Templates - GitHub