Skip to content

Grade-school: Structure very unclear #253

@colin-mullikin

Description

@colin-mullikin

The intended structure of the School class is very hard to pin down. All of the add() calls are done directly on the School, but then for the first few tests, things (size, added students) are accessed through an arbitrary middle layer, db(). After the first few tests, suddenly the calls change from school.db().get({grade number}) to school.grade({grade number}).

Examples:
school.add("Chelsea", 3);
assertThat(school.db().get(3).size(), is(1));
assertThat(school.grade(5).size(), is(2));

If the point of the exercise is to force adherence to an arbitrary (and frankly ridiculous) structure, then I would consider it a great success.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions