SmartConnector Forum
Schneider Electric support forum about SmartConnector applications for integration of other building management systems (BMS) into EcoStruxure Building Operation.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-03-23 11:18 AM
Link copied. Please paste this link to share this article on your social media post.
Yes it is, via Unit Testing.
Usually in a Smart Connector extension, there are at least two projects: the extension and the test project. What you would need to do to start:
1. Download a Test Runner, an external app or Visual Studio add-in that will let you test this code as it executes. If you already have something called ReSharper installed, then you have this.
a. From Visual Studio, Tools --> Extensions and Updates
b. Select "Online - Visual Studio Gallery"
c. In the Search field, type "NUnit" (this is the recommened one)
d. Download and Install NUnit Test Adapter 3
2. Install the Smart Connector Runtime. You can find out how to do this in Section 4 of the Smart Connector Installation and Configuration Guide, let me know if you don't have that
3. Add a new Class Library project to your Solution and preferably name it "[extensionName].Test"
4. Create your Unit Testing project. This is covering in Chapter 9 of the "Smart Connector Developer - Video Series" series on MyLearningLink. If you do not have access to that, tell me and I can link you to the series hosted on Teachable.com. It is a video adaptation of the Smart Connector Developer's Guide.
The material I mentioned in Step 4 will go over coding Unit tests and several other subtleties about the tests. There are three types that you will eventually set up: the one you want to run to test Execute_Sublcass is the ExecuteTest.
Posted: 2020-03-23 11:18 AM
Link copied. Please paste this link to share this article on your social media post.
Yes it is, via Unit Testing.
Usually in a Smart Connector extension, there are at least two projects: the extension and the test project. What you would need to do to start:
1. Download a Test Runner, an external app or Visual Studio add-in that will let you test this code as it executes. If you already have something called ReSharper installed, then you have this.
a. From Visual Studio, Tools --> Extensions and Updates
b. Select "Online - Visual Studio Gallery"
c. In the Search field, type "NUnit" (this is the recommened one)
d. Download and Install NUnit Test Adapter 3
2. Install the Smart Connector Runtime. You can find out how to do this in Section 4 of the Smart Connector Installation and Configuration Guide, let me know if you don't have that
3. Add a new Class Library project to your Solution and preferably name it "[extensionName].Test"
4. Create your Unit Testing project. This is covering in Chapter 9 of the "Smart Connector Developer - Video Series" series on MyLearningLink. If you do not have access to that, tell me and I can link you to the series hosted on Teachable.com. It is a video adaptation of the Smart Connector Developer's Guide.
The material I mentioned in Step 4 will go over coding Unit tests and several other subtleties about the tests. There are three types that you will eventually set up: the one you want to run to test Execute_Sublcass is the ExecuteTest.
Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.