Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chap 14.3 Page Layout #305

Open
anonymous12345654321 opened this issue Jun 24, 2024 · 0 comments
Open

Chap 14.3 Page Layout #305

anonymous12345654321 opened this issue Jun 24, 2024 · 0 comments

Comments

@anonymous12345654321
Copy link

From the book

def test_renders_a_column_of_two_blocks():
    fixture = Col(Block(1, 1), Block(2, 4))
    fixture.place(0, 0)
    expected = "\n".join(["ba", "cc", "cc", "cc", "cc"])
    assert render(fixture) == expected

Running this, results - for me - in an error, since Col do not have a .place method.
I think it should be a PlacedCol(PlacedBlock(1, 1), PlacedBlock(2, 4)).

Also

def test_renders_a_column_of_two_blocks():
    fixture = Col(Block(1, 1), Block(2, 4))
    fixture.place(0, 0)
    expected = "\n".join(["ba", "cc", "cc", "cc", "cc"])
    assert render(fixture) == expected

does not work for me, as no render function is defined.

Either I am doing something wrong or there is a bug (or both).

Anyway, thanks for sharing this great work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant