12345678910111213141516171819202122232425262728293031323334353637383940414243444546 |
- using DistinctChar;
- namespace DistinctCharsTest
- {
- [TestClass]
- public class DistinctCharsTest
- {
- [TestMethod]
- public void SetStr1_writeAbcd_Str1ContainAbcs()
- {
- DistinctChars obj = new DistinctChars();
- obj.Str1 = "abcd";
- string rezult = "abcd";
- Assert.AreEqual(obj.Str1, rezult);
- }
- [TestMethod]
- public void SetStr2_writeAbcd_Str2IsNotBcfd()
- {
- DistinctChars obj = new DistinctChars();
- obj.Str2 = "abcd";
- string rezult = "bcfd";
- Assert.AreNotEqual(obj.Str1, rezult);
- }
- [TestMethod]
- public void DistinctChars_SetAbcdeAndBcfr_GetAbcdef()
- {
- DistinctChars obj = new DistinctChars();
- obj.Str1 = "abcde";
- obj.Str2 = "bcfr";
- string rezult = "abcdef";
- Assert.AreEqual(obj.GetDistinctStr(), rezult);
- }
- [TestMethod]
- public void DistinctChars_SetAbcdeAndBcfr_GetNotAbcdebcfr()
- {
- DistinctChars obj = new DistinctChars();
- obj.Str1 = "abcde";
- obj.Str2 = "bcfr";
- string rezult = "abcdebcfr";
- Assert.AreNotEqual(obj.GetDistinctStr(), rezult);
- }
- }
- }
|