Ejemplo n.º 1
0
def test_global_settings():
    parts = {
        'index':
        trim("""
            My Document

            $ AUTHOR = Arthur C. Clarke

            ` Part One
            """),
    }
    settings = Settings()
    settings.extract(parts)
    assert settings._ == {'AUTHOR': 'Arthur C. Clarke'}
Ejemplo n.º 2
0
def test_multiline_authors():
    parts = {
        'index':
        trim("""
            My Document

            $ AUTHOR = Arthur C. Clarke
                     + Isaac Asimov

            ` Part One
            """),
    }
    settings = Settings()
    settings.extract(parts)
    assert settings._ == {'AUTHOR': 'Arthur C. Clarke + Isaac Asimov'}