????????г?????????
???????????????? ???????[ 2010/7/1 17:35:20 ] ????????
????4?????????????????(Sanitized Roundtrip)????????????????????????????????????????? 10?壬????е???????????????10???????????????????? 10????????????????????f-1(f(f-1(x)))=f-1(x)
????????????????????????δ???????檔
[TestMethod]
public void SanitizedRoundTripTest()
{
string str = " 10 ";
//?????????????????????????????????????????????????????
int i = Int32.Parse(str);
string intermediate = i.ToString();
int roundtripped = Int32.Parse(intermediate);
//??????
Assert.AreEqual(i?? roundtripped);
}
????5????????????????????????????????????????????????????????????????????????????????????????????
??????ζ??б???м?????????
[TestMethod]
public void InsertContains()
{
string input = "some string";
List<string> list = new List<string>();
list.Add(input);
Assert.IsTrue(list.Contains(input));
list.Remove(input);
Assert.IsFalse(list.Contains(input));
}
????6?????????????????????????????????????????????????????
[TestMethod??ExpectedException(typeof(IndexOutOfRangeException))]
public void ExpectedException()
{
//????????????5??????
int[] array = new int[5];
//???????????????λ???????????IndexOutOfRangeException??
array[6] = 1;
}
???????????????????????б?????????????????????????????????Щ???????????????????а??????
??????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11