def test_import_into_subreddit(self): sr = mock_wrapper() fixture = ImporterFixture() post_id = fixture.add_post() fixture.add_comment(post_id=post) importer = Importer() importer.import_into_subreddit(sr, fixture.get_data(), StringIO.StringIO())
def test_set_sort_order(self): fixture = ImporterFixture() post_id = fixture.add_post() fixture.add_comment(post) importer = Importer() sr = mock_wrapper() link = mock_wrapper() mock_link = mock_on(Link) mock_link.create.returning(link.mock).with_args().is_expected importer.import_into_subreddit(sr.mock, fixture.get_data(), StringIO.StringIO())
def test_import_into_subreddit(self): sr = mock() fixture = ImporterFixture() post_id = fixture.add_post() fixture.add_comment(post_id=post) importer = Importer() importer.import_into_subreddit(sr, fixture.get_data(), StringIO.StringIO())
def test_set_sort_order(self): fixture = ImporterFixture() post_id = fixture.add_post() fixture.add_comment(post) importer = Importer() sr = mock() link = mock() mock_link = mock_on(Link) mock_link.create.returning(link.raw).with_args().is_expected importer.import_into_subreddit(sr.raw, fixture.get_data(), StringIO.StringIO())