# Path: cum/config.py
# class BaseConfig(object):
# class MadokamiConfig(object):
#     def __init__(self):
#     def __setattr__(self, name, value):
#     def default_download_directory(self):
#     def load(self):
#     def serialize(self):
#     def write(self):
#     def __init__(self, config, dict):
#     def login(self):
# def get():
# def initialize(directory=None):


from cum import config
from unittest import mock
import cumtest
import datetime
             'alias': 'himegoto', 'name': 'Himegoto+'},
            {'url': ('https://manga.madokami.al/Manga/N/NU/NUDE/Nude%20na%20Shisen'),
             'alias': 'nude-na-shisen',
             'name': 'Nude na Shisen'}
        ]
        MESSAGES = [
            'Updating 2 series',
            'himegoto 1  2  3  4  5  6  7'
        ]

        config.get().compact_new = True
        config.get().write()

        for follow in FOLLOWS:
            series = self.create_mock_series(**follow)
            series.follow()
        chapters = self.db.session.query(self.db.Chapter).all()
        self.assertEqual(len(chapters), 0)

        result = self.invoke('update')
        chapters = self.db.session.query(self.db.Chapter).all()
        self.assertEqual(result.exit_code, 0)
        for message in MESSAGES:
            self.assertIn(message, result.output)
        self.assertEqual(len(chapters), 7)

    def test_update_fast(self):
        CHAPTERS2 = [
            {'chapter': '1',
             'url': ('https://kobato.hologfx.com/reader/read/'

# Path: cum/config.py
# class BaseConfig(object):
# class MadokamiConfig(object):
#     def __init__(self):
#     def __setattr__(self, name, value):
#     def default_download_directory(self):
#     def load(self):
#     def serialize(self):
#     def write(self):
#     def __init__(self, config, dict):
#     def login(self):
# def get():
# def initialize(directory=None):


# Path: tests/test_cli_update.py
from cum import config
from unittest import mock
import cumtest
import datetime

             'alias': 'himegoto', 'name': 'Himegoto+'},
            {'url': ('https://manga.madokami.al/Manga/N/NU/NUDE/Nude%20na%20Shisen'),
             'alias': 'nude-na-shisen',
             'name': 'Nude na Shisen'}
        ]
        MESSAGES = [
            'Updating 2 series',
            'himegoto 1  2  3  4  5  6  7'
        ]

        config.get().compact_new = True
        config.get().write()

        for follow in FOLLOWS:
            series = self.create_mock_series(**follow)
            series.follow()
        chapters = self.db.session.query(self.db.Chapter).all()
        self.assertEqual(len(chapters), 0)

        result = self.invoke('update')
        chapters = self.db.session.query(self.db.Chapter).all()
        self.assertEqual(result.exit_code, 0)
        for message in MESSAGES:
            self.assertIn(message, result.output)
        self.assertEqual(len(chapters), 7)

    def test_update_fast(self):
        CHAPTERS2 = [
            {'chapter': '1',
             'url': ('https://kobato.hologfx.com/reader/read/'

                     'hitoribocchi_no_oo_seikatsu/en/1/1/')},