Beispiel #1
0
    def test_remove_duplicates_true(self):
        result = utils.subscriptions_users_remove_duplicates(self.emails_1,
                                                             self.emails_1,
                                                             remove_same=True)

        assert set(result['none']) == set(['h1234', 'g1234', 'i1234'])
        assert result['email_digest'] == []
        assert result['email_transactional'] == []
Beispiel #2
0
 def test_remove_duplicates(self):
     result = utils.subscriptions_users_remove_duplicates(self.emails_1,
                                                          self.emails_4,
                                                          remove_same=False)
     assert set(self.dup_1_3['email_transactional']) == set(
         result['email_transactional'])
     assert set(self.dup_1_3['none']) == set(result['none'])
     assert set(self.dup_1_3['email_digest']) == set(result['email_digest'])
Beispiel #3
0
 def test_remove_duplicates_true(self):
     result = utils.subscriptions_users_remove_duplicates(self.emails_1,
                                                          self.emails_1,
                                                          remove_same=True)
     assert_equal(
         {
             email_digest: [],
             email_transactional: [],
             'none': ['h1234', 'g1234', 'i1234']
         }, result)
Beispiel #4
0
 def test_remove_duplicates(self):
     result = utils.subscriptions_users_remove_duplicates(self.emails_1,
                                                          self.emails_4,
                                                          remove_same=False)
     assert_equal(self.dup_1_3, result)
Beispiel #5
0
 def test_remove_duplicates_true(self):
     result = utils.subscriptions_users_remove_duplicates(
         self.emails_1, self.emails_1, remove_same=True
     )
     assert_equal({email_digest: [], email_transactional: [], 'none': ['h1234', 'g1234', 'i1234']}, result)
Beispiel #6
0
 def test_remove_duplicates(self):
     result = utils.subscriptions_users_remove_duplicates(
         self.emails_1, self.emails_4, remove_same=False
     )
     assert_equal(self.dup_1_3, result)