-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathGetProductInfo.cs
More file actions
36 lines (30 loc) · 1.14 KB
/
GetProductInfo.cs
File metadata and controls
36 lines (30 loc) · 1.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
using Kepware.Api.Model;
using Moq;
using Moq.Contrib.HttpClient;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Text;
using System.Threading.Tasks;
namespace Kepware.Api.TestIntg.ApiClient
{
public class GetProductInfo : TestApiClientBase
{
[Fact]
public async Task GetProductInfoAsync_ShouldReturnProductInfo_WhenApiRespondsSuccessfully()
{
// Act
var result = await _kepwareApiClient.GetProductInfoAsync();
// Assert
Assert.NotNull(result);
Assert.Equal(_productInfo.ProductId, result.ProductId);
Assert.Equal(_productInfo.ProductName, result.ProductName);
Assert.Equal(_productInfo.ProductVersion, result.ProductVersion);
Assert.Equal(_productInfo.ProductVersionMajor, result.ProductVersionMajor);
Assert.Equal(_productInfo.ProductVersionMinor, result.ProductVersionMinor);
Assert.Equal(_productInfo.ProductVersionBuild, result.ProductVersionBuild);
Assert.Equal(_productInfo.ProductVersionPatch, result.ProductVersionPatch);
}
}
}