-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path_0791_Custom_sort_string_Test.cs
More file actions
41 lines (34 loc) · 1.01 KB
/
_0791_Custom_sort_string_Test.cs
File metadata and controls
41 lines (34 loc) · 1.01 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
37
38
39
40
41
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Solution._0791.Custom_sort_string;
namespace _0791.Custom_sort_string.Tests
{
[TestClass()]
public class _0791_Custom_sort_string_Test
{
_0791_Custom_sort_string solution = new _0791_Custom_sort_string();
[TestMethod()]
public void CustomSortString_Test1()
{
// Arrange
string order = "cba";
string str = "abcd";
var expected = "cbad";
// Act
var actual = solution.CustomSortString(order, str);
// Assert
Assert.AreEqual(expected, actual);
}
[TestMethod()]
public void CustomSortString_Test2()
{
// Arrange
string order = "cbafg";
string str = "abcd";
var expected = "cbad";
// Act
var actual = solution.CustomSortString(order, str);
// Assert
Assert.AreEqual(expected, actual);
}
}
}