use of com.android.common.Rfc822Validator in project Etar-Calendar by Etar-Group.
the class EditEventHelperTest method setUp.
@Override
public void setUp() {
Time time = new Time(Time.TIMEZONE_UTC);
time.set(TEST_START);
time.timezone = LOCAL_TZ;
TEST_START2 = time.normalize(true);
time.timezone = Time.TIMEZONE_UTC;
time.set(TEST_END);
time.timezone = LOCAL_TZ;
TEST_END2 = time.normalize(true);
mEmailValidator = new Rfc822Validator(null);
}
use of com.android.common.Rfc822Validator in project Etar-Calendar by Etar-Group.
the class EditEventHelperTest method testGetAddressesFromList.
@Smoke
@SmallTest
public void testGetAddressesFromList() {
mActivity = buildTestContext();
mHelper = new EditEventHelper(mActivity, null);
LinkedHashSet<Rfc822Token> expected = new LinkedHashSet<Rfc822Token>();
expected.add(new Rfc822Token(null, "ad1@email.com", ""));
expected.add(new Rfc822Token("First Last", "first@email.com", "comment"));
expected.add(new Rfc822Token(null, "one.two.three@email.grue", ""));
LinkedHashSet<Rfc822Token> actual = mHelper.getAddressesFromList(TEST_ADDRESSES, new Rfc822Validator(null));
assertEquals(expected, actual);
}
Aggregations