From 57694cb3521f19a42b847a6cf927064ce757e43c Mon Sep 17 00:00:00 2001 From: Richard Harding Date: Sat, 21 Apr 2012 08:16:18 -0400 Subject: [PATCH] Remove the get_ in method name, doesn't fit rest of api --- src/readability_lxml/readability.py | 2 +- src/tests/test_article_only.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/readability_lxml/readability.py b/src/readability_lxml/readability.py index d97d974..1dc3dbe 100755 --- a/src/readability_lxml/readability.py +++ b/src/readability_lxml/readability.py @@ -145,7 +145,7 @@ class Document: def short_title(self): return shorten_title(self.html) - def get_summary_with_metadata(self, enclose_with_html_tag=True): + def summary_with_metadata(self, enclose_with_html_tag=True): """Parse the input content and return a Summary object :param enclose_with_html_tag: Bool do you want a full document diff --git a/src/tests/test_article_only.py b/src/tests/test_article_only.py index fc8518f..4575f30 100644 --- a/src/tests/test_article_only.py +++ b/src/tests/test_article_only.py @@ -41,7 +41,7 @@ class TestArticleOnly(unittest.TestCase): """We should parse the doc and get a full summary with confidence""" sample = load_sample('si-game.sample.html') doc = Document(sample, url='http://sportsillustrated.cnn.com/baseball/mlb/gameflash/2012/04/16/40630_preview.html') - res = doc.get_summary_with_metadata(enclose_with_html_tag=False) + res = doc.summary_with_metadata(enclose_with_html_tag=False) self.assertTrue(hasattr(res, 'html'), 'res should have an html attrib') self.assertTrue(hasattr(res, 'confidence'), 'res should have an html attrib') self.assertEqual('