Example #1
0
    def testCheckingReturnStatus(self):
        generator = checking.generator([self.status] * 2, return_status=True)
        assert isinstance(next(generator), tweepy.Status)

        generator = checking.generator([self.status] * 2, return_status=False)
        self.assertTrue(isinstance(next(generator), basestring))

        generator = checking.generator(self.archive, return_status=True)
        self.assertTrue(isinstance(next(generator), dict))
Example #2
0
    def testCheckingReturnStatus(self):
        generator = checking.generator([self.status] * 2, return_status=True)
        assert isinstance(next(generator), tweepy.Status)

        generator = checking.generator([self.status] * 2, return_status=False)
        self.assertTrue(isinstance(next(generator), basestring))

        generator = checking.generator(self.archive, return_status=True)
        self.assertTrue(isinstance(next(generator), dict))
Example #3
0
 def test_reply_filtering_txtfile(self):
     generator = checking.generator(self.txt, txt=1, no_replies=1)
     self.assertEqual(len(list(generator)), 99)
Example #4
0
 def test_rt_filtering_archive(self):
     generator = checking.generator(self.archive, no_retweets=1)
     lis = list(generator)
     self.assertEqual(len(lis), 98)
Example #5
0
 def test_rt_filtering(self):
     generator = checking.generator(self.txt, txt=1, no_retweets=1)
     self.assertEqual(len(list(generator)), 99)
Example #6
0
 def test_reply_filtering_archive(self):
     generator = checking.generator(self.archive, no_replies=1)
     self.assertEqual(len(list(generator)), 98)
Example #7
0
 def test_rt_filtering_archive(self):
     generator = checking.generator(self.archive, no_retweets=1)
     lis = list(generator)
     self.assertEqual(len(lis), 98)
Example #8
0
 def test_rt_filtering(self):
     generator = checking.generator(self.txt, txt=1, no_retweets=1)
     self.assertEqual(len(list(generator)), 99)
Example #9
0
 def test_reply_filtering_archive(self):
     generator = checking.generator(self.archive, no_replies=1)
     self.assertEqual(len(list(generator)), 98)
Example #10
0
 def test_reply_filtering_txtfile(self):
     generator = checking.generator(self.txt, txt=1, no_replies=1)
     self.assertEqual(len(list(generator)), 99)