-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path_1370_Increasing_decreasin_string_Test.cs
More file actions
81 lines (65 loc) · 1.88 KB
/
_1370_Increasing_decreasin_string_Test.cs
File metadata and controls
81 lines (65 loc) · 1.88 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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Solution._1370.Increasing_decreasin_string;
namespace _1370.Increasing_decreasin_string.Tests
{
[TestClass()]
public class _1370_Increasing_decreasin_string_Test
{
_1370_Increasing_decreasin_string solution = new _1370_Increasing_decreasin_string();
[TestMethod()]
public void SortString_Test1()
{
// Arrange
string s = "aaaabbbbcccc";
var expected = "abccbaabccba";
// Act
var actual = solution.SortString(s);
// Assert
Assert.AreEqual(expected, actual);
}
[TestMethod()]
public void SortString_Test2()
{
// Arrange
string s = "rat";
var expected = "art";
// Act
var actual = solution.SortString(s);
// Assert
Assert.AreEqual(expected, actual);
}
[TestMethod()]
public void SortString_Test3()
{
// Arrange
string s = "leetcode";
var expected = "cdelotee";
// Act
var actual = solution.SortString(s);
// Assert
Assert.AreEqual(expected, actual);
}
[TestMethod()]
public void SortString_Test4()
{
// Arrange
string s = "ggggggg";
var expected = "ggggggg";
// Act
var actual = solution.SortString(s);
// Assert
Assert.AreEqual(expected, actual);
}
[TestMethod()]
public void SortString_Test5()
{
// Arrange
string s = "spo";
var expected = "ops";
// Act
var actual = solution.SortString(s);
// Assert
Assert.AreEqual(expected, actual);
}
}
}