Beispiel #1
0
		public void TestGetResponseCodeType ()
		{
			foreach (ImapResponseCodeType type in Enum.GetValues (typeof (ImapResponseCodeType))) {
				string atom;

				switch (type) {
				case ImapResponseCodeType.ReadOnly: atom = "READ-ONLY"; break;
				case ImapResponseCodeType.ReadWrite: atom = "READ-WRITE"; break;
				case ImapResponseCodeType.UnknownCte: atom = "UNKNOWN-CTE"; break;
				case ImapResponseCodeType.UndefinedFilter: atom = "UNDEFINED-FILTER"; break;
				default: atom = type.ToString ().ToUpperInvariant (); break;
				}

				var result = ImapEngine.GetResponseCodeType (atom);
				Assert.AreEqual (type, result);
			}
		}