aboutsummaryrefslogtreecommitdiffstats
path: root/test_gg_scrapper.py
diff options
context:
space:
mode:
authorMatěj Cepl <mcepl@redhat.com>2013-12-28 00:27:09 +0100
committerMatěj Cepl <mcepl@redhat.com>2013-12-28 00:51:43 +0100
commit58ec4876d8dd638de14c2ccb3d959c40eadfe2d8 (patch)
tree02e70224d63e15ef137b967a55d8f24abe56bee1 /test_gg_scrapper.py
parent9dcfa6e10d512cb767dac9c410c96072f7cbd166 (diff)
downloadgg_scraper-58ec4876d8dd638de14c2ccb3d959c40eadfe2d8.tar.gz
Convert to python3.
Diffstat (limited to 'test_gg_scrapper.py')
-rw-r--r--test_gg_scrapper.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/test_gg_scrapper.py b/test_gg_scrapper.py
index 1a75aab..10e7f4a 100644
--- a/test_gg_scrapper.py
+++ b/test_gg_scrapper.py
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
-from __future__ import unicode_literals, print_function, absolute_import
+
import logging
import unittest
import gg_scrapper
@@ -12,16 +12,16 @@ EXP_URL = 'https://groups.google.com/forum/' + \
class TestGGScrapper(unittest.TestCase):
def test_URL_conversion(self):
- obs_URL = gg_scrapper.GooglePage.unenscape_Google_bang_URL(IN_URL)
+ obs_URL = gg_scrapper.Group.unenscape_Google_bang_URL(IN_URL)
self.assertEqual(obs_URL, EXP_URL)
def test_do_redirect(self):
- obs_URL = gg_scrapper.GooglePage.do_redirect(ORIG_URL)
+ obs_URL = gg_scrapper.Group.do_redirect(ORIG_URL)
self.assertEqual(obs_URL, EXP_URL)
def test_collecting_topics(self):
- page = gg_scrapper.GooglePage(IN_URL)
- topics = page.get_topics(page.bs_page)
+ page = gg_scrapper.Group(IN_URL)
+ topics = page.get_topics()
logging.debug("number of topics = %d", len(topics))
self.assertGreater(len(topics), 0)